Add user comment to transaction propossal

This commit is contained in:
Yemel Jardi 2014-06-13 10:33:30 -03:00
commit bcbb6b54d1
8 changed files with 93 additions and 15 deletions

View file

@ -47,19 +47,18 @@ angular.module('copayApp.controllers').controller('SendController',
var address = form.address.$modelValue;
var amount = (form.amount.$modelValue * 100000000).toFixed(); // satoshi to string
var comment = form.comment.$modelValue;
var w = $rootScope.wallet;
w.createTx(address, amount,function() {
w.createTx(address, amount, comment, function() {
$scope.loading = false;
$rootScope.$flashMessage = { message: 'The transaction proposal has been created', type: 'success'};
$rootScope.$digest();
});
// reset fields
$scope.address = null;
$scope.amount = null;
form.address.$pristine = true;
form.amount.$pristine = true;
$scope.address = $scope.amount = $scope.comment = null;
form.address.$pristine = form.amount.$pristine = form.comment.$pristine = true;
};
// QR code Scanner