Commit 3a15cf255e316118f31f8a00fa1763a96f01fab5
Exists in
master
Merge branch 'master' of https://debo.suite.repo/modulos-npm/foca-crear-nota-pedido
Showing
1 changed file
Show diff stats
src/js/controller.js
1 | 1 | angular.module('focaCrearNotaPedido') .controller('notaPedidoCtrl', |
2 | 2 | [ |
3 | 3 | '$scope', '$uibModal', '$location', '$filter', 'crearNotaPedidoService', |
4 | - 'focaModalService', 'notaPedidoBusinessService', '$rootScope', | |
4 | + 'focaModalService', 'notaPedidoBusinessService', '$rootScope', 'focaSeguimientoService', | |
5 | 5 | function( |
6 | 6 | $scope, $uibModal, $location, $filter, crearNotaPedidoService, focaModalService, |
7 | - notaPedidoBusinessService, $rootScope | |
7 | + notaPedidoBusinessService, $rootScope, focaSeguimientoService | |
8 | 8 | ) { |
9 | 9 | $scope.botonera = [ |
10 | 10 | {texto: 'Vendedor', accion: function() { |
... | ... | @@ -180,6 +180,16 @@ angular.module('focaCrearNotaPedido') .controller('notaPedidoCtrl', |
180 | 180 | }; |
181 | 181 | crearNotaPedidoService.crearNotaPedido(notaPedido).then( |
182 | 182 | function(data) { |
183 | + // Al guardar los datos de la nota de pedido logueamos la | |
184 | + // actividad para su seguimiento. | |
185 | + focaSeguimientoService.guardarPosicion( | |
186 | + $scope.notaPedido.vendedor.codigo, | |
187 | + 'Nota de pedido', | |
188 | + 'Nº: ' + $filter('comprobante')([ | |
189 | + $scope.puntoVenta, | |
190 | + $scope.comprobante | |
191 | + ]) | |
192 | + ); | |
183 | 193 | notaPedidoBusinessService.addArticulos($scope.articulosTabla, |
184 | 194 | data.data.id, $scope.notaPedido.cotizacion.VENDEDOR); |
185 | 195 | var plazos = $scope.plazosPagos; |