add message and id to new tx proposal
@ -1992,7 +1992,9 @@ WalletService.prototype.publishTx = function(opts, cb) {
if (err) return cb(err);
self._notify('NewTxProposal', {
amount: txp.getTotalAmount()
amount: txp.getTotalAmount(),
txProposalId: txp.id,
message: txp.message,
}, function() {
return cb(null, txp);
});
@ -2605,7 +2605,12 @@ describe('Wallet service', function() {
should.not.exist(err);
server.getNotifications({}, function(err, notifications) {
_.pluck(notifications, 'type').should.contain('NewTxProposal');
var n = _.find(notifications, {'type': 'NewTxProposal'});
should.exist(n);
should.exist(n.data.txProposalId);
should.exist(n.data.message);
done();