Wallet/src/js/controllers/topbar.js
Kosta Korenkov 1f4f78bec0 Make directive to accept onScan and beforeScan callbacks instead of broadcasting 'dataScanned' event.
This will allow to reuse directive for screens different from 'send'
2015-07-23 13:21:31 +03:00

17 lines
322 B
JavaScript

'use strict';
angular.module('copayApp.controllers').controller('topbarController', function($rootScope, go) {
this.onQrCodeScanned = function(data) {
$rootScope.$emit('dataScanned', data);
};
this.openSendScreen = function() {
go.send();
};
this.goHome = function() {
go.walletHome();
};
});