Commit 8509fcae556048ced291da64b925be3c2cf4a0d5

Authored by Nicolás Guarnieri
Exists in master

Merge branch 'master' into 'master'

Master

See merge request !1
src/js/controller.js
1 angular.module('focaModalEfectivo') 1 angular.module('focaModalEfectivo')
2 .controller('focaModalEfectivoController', 2 .controller('focaModalEfectivoController',
3 [ 3 [
4 '$scope', 4 '$scope',
5 '$uibModalInstance', 5 '$uibModalInstance',
6 function($scope, $uibModalInstance) { 6 function($scope, $uibModalInstance) {
7 $scope.aceptar = function(key) { 7 $scope.aceptar = function(key) {
8 if(key === 13) { 8 if(key === 13 && $scope.efectivo) {
9 var efectivo = parseFloat($scope.efectivo); 9 var efectivo = parseFloat($scope.efectivo);
10 $uibModalInstance.close(efectivo); 10 $uibModalInstance.close(efectivo);
11 } 11 }
12 }; 12 };
13 13
14 $scope.cancel = function() { 14 $scope.cancel = function() {
15 $uibModalInstance.dismiss('cancel'); 15 $uibModalInstance.dismiss('cancel');
16 }; 16 };
17 } 17 }
18 ] 18 ]
19 ); 19 );
20 20