if received then show addresses received at
This commit is contained in:
parent
f7c95c531e
commit
7384ad3e63
2 changed files with 30 additions and 6 deletions
|
|
@ -122,9 +122,17 @@ angular.module('copayApp.controllers').controller('txDetailsController', functio
|
|||
var txDate = new Date(($scope.btx.createdOn || $scope.btx.time) * 1000);
|
||||
|
||||
if ($scope.wallet.coin == 'bch' && txDate >= cashaddrDate) {
|
||||
var bchAddresses = bitcoinCashJsService.translateAddresses($scope.btx.addressTo);
|
||||
$scope.btx.cashAddr = bchAddresses.cashaddr;
|
||||
$scope.btx.cashCopyAddr = 'bitcoincash:' + $scope.btx.cashAddr;
|
||||
if ($scope.btx.action === 'sent') {
|
||||
var bchAddresses = bitcoinCashJsService.translateAddresses($scope.btx.addressTo);
|
||||
$scope.btx.cashAddr = bchAddresses.cashaddr;
|
||||
$scope.btx.cashCopyAddr = 'bitcoincash:' + $scope.btx.cashAddr;
|
||||
} else {
|
||||
lodash.each($scope.btx.outputs, function(o) {
|
||||
var bchAddresses = bitcoinCashJsService.translateAddresses(o.address);
|
||||
o.cashAddr = bchAddresses.cashaddr;
|
||||
});
|
||||
console.log($scope.btx.outputs);
|
||||
}
|
||||
}
|
||||
|
||||
$scope.btx.displayAddress = $scope.btx.addressTo;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue