Commit c3549f34ca115cbb2f47ecef87ef246154db1e01
Exists in
master
and in
1 other branch
Merge branch 'master' into 'develop'
Master See merge request !58
Showing
1 changed file
Show diff stats
src/js/controller.js
... | ... | @@ -193,8 +193,6 @@ angular.module('focaCrearRemito') .controller('remitoController', |
193 | 193 | } |
194 | 194 | |
195 | 195 | $scope.remito.articulosRemito = notaPedido.articulosNotaPedido; |
196 | - remitoBusinessService.calcularArticulos($scope.remito.articulosRemito, | |
197 | - notaPedido.cotizacion.VENDEDOR); | |
198 | 196 | |
199 | 197 | if (notaPedido.idPrecioCondicion > 0) { |
200 | 198 | $scope.idLista = notaPedido.precioCondicion.idListaPrecio; |
... | ... | @@ -739,7 +737,6 @@ angular.module('focaCrearRemito') .controller('remitoController', |
739 | 737 | } else { |
740 | 738 | $scope.$broadcast('removeCabecera', 'Bomba:'); |
741 | 739 | $scope.$broadcast('removeCabecera', 'Kilometros:'); |
742 | - $scope.remito.fob = false; | |
743 | 740 | $scope.remito.bomba = false; |
744 | 741 | $scope.remito.kilometros = null; |
745 | 742 | } |
... | ... | @@ -1001,11 +998,11 @@ angular.module('focaCrearRemito') .controller('remitoController', |
1001 | 998 | ' - ' + remito.proveedor.NOM |
1002 | 999 | }); |
1003 | 1000 | } |
1004 | - if (remito.flete !== undefined) { | |
1001 | + if (remito.flete !== undefined && remito.fob !== undefined) { | |
1005 | 1002 | cabeceras.push({ |
1006 | 1003 | label: 'Flete:', |
1007 | - valor: remito.fob === 1 ? 'FOB' : ( | |
1008 | - remito.flete === 1 ? 'Si' : 'No') | |
1004 | + valor: remito.fob ? 'FOB' : ( | |
1005 | + remito.flete ? 'Si' : 'No') | |
1009 | 1006 | }); |
1010 | 1007 | } |
1011 | 1008 | if (remito.remitoPlazo) { |
... | ... | @@ -1015,7 +1012,6 @@ angular.module('focaCrearRemito') .controller('remitoController', |
1015 | 1012 | remitoBusinessService.plazoToString(remito.remitoPlazo) |
1016 | 1013 | }); |
1017 | 1014 | } |
1018 | - | |
1019 | 1015 | function valorPrecioCondicion() { |
1020 | 1016 | if (remito.idPrecioCondicion > 0) { |
1021 | 1017 | return remito.precioCondicion.nombre; |
... | ... | @@ -1023,7 +1019,6 @@ angular.module('focaCrearRemito') .controller('remitoController', |
1023 | 1019 | return 'Ingreso Manual'; |
1024 | 1020 | } |
1025 | 1021 | } |
1026 | - | |
1027 | 1022 | if (remito.flete === 1) { |
1028 | 1023 | var cabeceraBomba = { |
1029 | 1024 | label: 'Bomba', |
... | ... | @@ -1039,8 +1034,7 @@ angular.module('focaCrearRemito') .controller('remitoController', |
1039 | 1034 | cabeceras.push(cabeceraBomba); |
1040 | 1035 | } |
1041 | 1036 | $scope.remito.articulosRemito = remito.articulosRemito; |
1042 | - remitoBusinessService.calcularArticulos($scope.remito.articulosRemito, | |
1043 | - remito.cotizacion.VENDEDOR); | |
1037 | + | |
1044 | 1038 | if (remito.idPrecioCondicion > 0) { |
1045 | 1039 | $scope.idLista = remito.precioCondicion.idListaPrecio; |
1046 | 1040 | } else { |