Allow addons to customize pending proposals

This commit is contained in:
Kosta Korenkov 2015-08-03 15:49:44 +03:00
commit 6e37cb3017
2 changed files with 9 additions and 0 deletions

View file

@ -488,6 +488,7 @@ angular.module('copayApp.controllers').controller('indexController', function($r
if (tx.creatorId != self.copayerId) {
self.pendingTxProposalsCountForUs = self.pendingTxProposalsCountForUs + 1;
}
addonManager.formatPendingTxp(tx);
});
self.txps = txps;
};

View file

@ -19,4 +19,12 @@ angular.module('copayApp.services').service('addonManager', function (lodash) {
});
};
this.formatPendingTxp = function (txp) {
lodash.each(addons, function (addon) {
if (addon.formatPendingTxp) {
addon.formatPendingTxp(txp);
}
});
};
});