fix time format
This commit is contained in:
parent
880e3ebe14
commit
faab393dc0
2 changed files with 12 additions and 0 deletions
|
|
@ -25,4 +25,10 @@ angular.module('copayApp.controllers').controller('proposalsController',
|
|||
});
|
||||
|
||||
$scope.openTxpModal = txpModalService.open;
|
||||
|
||||
$scope.createdWithinPastDay = function(time) {
|
||||
var now = new Date();
|
||||
var date = new Date(time * 1000);
|
||||
return (now.getTime() - date.getTime()) < (1000 * 60 * 60 * 24);
|
||||
};
|
||||
});
|
||||
|
|
|
|||
|
|
@ -126,6 +126,12 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
|||
});
|
||||
});
|
||||
|
||||
$scope.createdWithinPastDay = function(time) {
|
||||
var now = new Date();
|
||||
var date = new Date(time * 1000);
|
||||
return (now.getTime() - date.getTime()) < (1000 * 60 * 60 * 24);
|
||||
};
|
||||
|
||||
$scope.openExternalLink = function() {
|
||||
var url = 'https://github.com/bitpay/copay/releases/latest';
|
||||
var optIn = true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue