Commit a93cf44e37fd5bec7a4faa7fd13d8616eec6b7bf
1 parent
3a15cf255e
Exists in
master
Obtengo el número de nota pedido al guardar
Showing
1 changed file
with
10 additions
and
0 deletions
Show diff stats
src/js/controller.js
... | ... | @@ -207,6 +207,16 @@ angular.module('focaCrearNotaPedido') .controller('notaPedidoCtrl', |
207 | 207 | $filter('date')($scope.notaPedido.cotizacion.FECHA, 'dd/MM/yyyy') |
208 | 208 | ); |
209 | 209 | addCabecera('Cotizacion:', $scope.notaPedido.cotizacion.VENDEDOR); |
210 | + crearNotaPedidoService.getNumeroNotaPedido().then( | |
211 | + function(res) { | |
212 | + $scope.puntoVenta = rellenar(res.data.sucursal, 4); | |
213 | + $scope.comprobante = rellenar(res.data.numeroNotaPedido, 8); | |
214 | + }, | |
215 | + function(err) { | |
216 | + focaModalService.alert('La terminal no esta configurada correctamente'); | |
217 | + console.info(err); | |
218 | + } | |
219 | + ); | |
210 | 220 | $scope.notaPedido.vendedor = {}; |
211 | 221 | $scope.notaPedido.cliente = {}; |
212 | 222 | $scope.notaPedido.proveedor = {}; |