Commit f4b1e80e350891d3da392a12457c1831493fa1bc

Authored by Jose Pinto
1 parent e84b5020b9
Exists in master

elimino facturas al seleccionar cliente

Showing 2 changed files with 21 additions and 3 deletions   Show diff stats
spec/controllerSpec.js
... ... @@ -524,14 +524,31 @@ describe('controladores módulo crear cobranza', function() {
524 524 return {
525 525 then: function() { }
526 526 };
  527 + },
  528 + getCobradorById: function() {
  529 + return {
  530 + then: function() { }
  531 + };
  532 + }
  533 + },
  534 + focaModalService: {
  535 + modal: function() {
  536 + return {
  537 + then: function() {}
  538 + };
527 539 }
528 540 },
529   - focaModalService: {},
530 541 $filter: $filter,
531 542 focaSeguimientoService: {},
532 543 focaBotoneraLateralService: {},
533   - APP: {},
534   - focaLoginService: {},
  544 + APP: 'cobranza',
  545 + focaLoginService: {
  546 + getLoginData: function() {
  547 + return {
  548 + vendedorCobrador: true
  549 + };
  550 + }
  551 + },
535 552 $localStorage: true
536 553 });
537 554 scope.cobranza = {
src/js/controller.js
... ... @@ -409,6 +409,7 @@ angular.module('focaCrearCobranza') .controller('cobranzaController',
409 409 clienteMayus.NOM
410 410 });
411 411 $scope.cobranza.cliente = clienteMayus;
  412 + $scope.cobranza.facturas = [];
412 413 }, function() {
413 414 if (APP !== 'cobranza') $scope.seleccionarCliente();
414 415 }