Commit 319289067566cca6d29b7e47b72abb4ff2a99618

Authored by Eric Fernandez
Exists in master

Merge branch 'master' into 'develop'

Master(efernandez)

See merge request !11
src/js/controller.js
... ... @@ -106,6 +106,7 @@ angular.module('focaCrearFactura').controller('facturaController', [
106 106 });
107 107  
108 108 $scope.factura.vendedor = res.data;
  109 + $scope.inicial.vendedor = res.data;
109 110  
110 111 getProductosByPlanilla(res.data.NplVen);
111 112 })
... ... @@ -450,6 +451,13 @@ angular.module('focaCrearFactura').controller('facturaController', [
450 451 function getProductosByPlanilla(numeroPlanilla) {
451 452  
452 453 crearFacturaService.getProductosByPlanilla(numeroPlanilla).then(function (res) {
  454 +
  455 + if (!res.data.length) {
  456 +
  457 + focaModalService.alert('No hay despachos disponibles por el momento');
  458 + return;
  459 + }
  460 +
453 461 $scope.botoneraProductos.length = 0;
454 462 res.data.forEach(function (producto) {
455 463