isolate change specific to action = received
This commit is contained in:
parent
07b9fb3921
commit
949550c35d
2 changed files with 15 additions and 12 deletions
|
|
@ -30,18 +30,20 @@
|
||||||
|
|
||||||
<ul class="no-bullet size-14 m0">
|
<ul class="no-bullet size-14 m0">
|
||||||
<div ng-if="btx.action == 'received'">
|
<div ng-if="btx.action == 'received'">
|
||||||
<li class="line-b p10 oh">
|
<li class="line-b p10 oh" ng-if="btx.message">
|
||||||
<span class="text-gray" translate>Note</span>:
|
<span class="text-gray" translate>Note</span>:
|
||||||
<span class="right">{{btx.message}}</span>
|
<span class="right">{{btx.message}}</span>
|
||||||
</li>
|
</li>
|
||||||
</div>
|
</div>
|
||||||
<div ng-if="!btx.showSingle && btx.action != 'received'"
|
<div ng-if="btx.action != 'received'">
|
||||||
ng-repeat="output in [ btx.outputs.summary ]"
|
<div ng-if="!btx.showSingle"
|
||||||
ng-include="'views/includes/output.html'">
|
ng-repeat="output in [ btx.outputs.summary ]"
|
||||||
</div>
|
ng-include="'views/includes/output.html'">
|
||||||
<div ng-if="!btx.showSingle && btx.outputs.summary.showDetails && btx.action != 'received'"
|
</div>
|
||||||
ng-repeat="output in btx.outputs.details"
|
<div ng-if="!btx.showSingle && btx.outputs.summary.showDetails"
|
||||||
ng-include="'views/includes/output.html'">
|
ng-repeat="output in btx.outputs.details"
|
||||||
|
ng-include="'views/includes/output.html'">
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<li ng-if="btx.showSingle && btx.addressTo && btx.addressTo != 'N/A'" class="line-b p10 oh" ng-click="copyAddress(btx.addressTo)">
|
<li ng-if="btx.showSingle && btx.addressTo && btx.addressTo != 'N/A'" class="line-b p10 oh" ng-click="copyAddress(btx.addressTo)">
|
||||||
<span class="text-gray" translate>To</span>:
|
<span class="text-gray" translate>To</span>:
|
||||||
|
|
|
||||||
|
|
@ -430,11 +430,12 @@ angular.module('copayApp.controllers').controller('indexController', function($r
|
||||||
if (tx.outputs) {
|
if (tx.outputs) {
|
||||||
tx.showSingle = false;
|
tx.showSingle = false;
|
||||||
tx.outputs.details = lodash.clone(tx.outputs);
|
tx.outputs.details = lodash.clone(tx.outputs);
|
||||||
|
var total = lodash.reduce(tx.outputs.details, function(total, o) {
|
||||||
|
formatAmount(o);
|
||||||
|
return total + o.amount;
|
||||||
|
}, 0);
|
||||||
if (tx.action != 'received') {
|
if (tx.action != 'received') {
|
||||||
tx.amount = lodash.reduce(tx.outputs.details, function(total, o) {
|
tx.amount = total;
|
||||||
formatAmount(o);
|
|
||||||
return total + o.amount;
|
|
||||||
}, 0);
|
|
||||||
}
|
}
|
||||||
tx.outputs.summary = {
|
tx.outputs.summary = {
|
||||||
amount: tx.amount,
|
amount: tx.amount,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue