Commit 4b63e4145a64bf34fc9bacf4c094fa51bccc94a5
1 parent
c85b6a3401
Exists in
master
trabajo realizado
Showing
5 changed files
with
93 additions
and
215 deletions
Show diff stats
gulpfile.js
package.json
... | ... | @@ -18,6 +18,7 @@ |
18 | 18 | "angular-route": "^1.7.5", |
19 | 19 | "bootstrap": "^4.1.3", |
20 | 20 | "foca-directivas": "git+https://debo.suite.repo/modulos-npm/foca-directivas.git", |
21 | + "foca-modal-remito": "git+https://debo.suite.repo/modulos-npm/foca-modal-remito.git", | |
21 | 22 | "font-awesome": "^4.7.0", |
22 | 23 | "gulp": "^3.9.1", |
23 | 24 | "gulp-angular-templatecache": "^2.2.5", |
src/js/app.js
src/js/controller.js
... | ... | @@ -26,29 +26,14 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
26 | 26 | }; |
27 | 27 | |
28 | 28 | $scope.hojaRuta = { |
29 | + fecha: new Date(), | |
29 | 30 | vendedor: {}, |
30 | 31 | cliente: {}, |
31 | - proveedor: {}, | |
32 | + transportista: {}, | |
32 | 33 | domicilio: {dom: ''}, |
33 | 34 | moneda: {}, |
34 | 35 | cotizacion: {} |
35 | 36 | }; |
36 | - var monedaPorDefecto; | |
37 | - //Trabajo con la cotización más reciente, por eso uso siempre la primera '[0]' | |
38 | - crearHojaRutaService.getCotizacionByIdMoneda(1).then(function(res) { | |
39 | - monedaPorDefecto = { | |
40 | - id: res.data[0].ID, | |
41 | - detalle: res.data[0].DETALLE, | |
42 | - simbolo: res.data[0].SIMBOLO, | |
43 | - cotizaciones: res.data[0].cotizaciones | |
44 | - }; | |
45 | - addCabecera('Moneda:', monedaPorDefecto.detalle); | |
46 | - addCabecera('Fecha cotizacion:', | |
47 | - new Date(monedaPorDefecto.cotizaciones[0].FECHA).toLocaleDateString()); | |
48 | - addCabecera('Cotizacion:', monedaPorDefecto.cotizaciones[0].COTIZACION); | |
49 | - $scope.hojaRuta.moneda = monedaPorDefecto; | |
50 | - $scope.hojaRuta.cotizacion = monedaPorDefecto.cotizaciones[0]; | |
51 | - }); | |
52 | 37 | |
53 | 38 | $scope.cabecera = []; |
54 | 39 | $scope.showCabecera = true; |
... | ... | @@ -56,21 +41,16 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
56 | 41 | $scope.now = new Date(); |
57 | 42 | $scope.puntoVenta = '0000'; |
58 | 43 | $scope.comprobante = '00000000'; |
59 | - $scope.articulosTabla = []; | |
44 | + $scope.remitosTabla = []; | |
60 | 45 | $scope.idLista = undefined; |
46 | + $ | |
61 | 47 | //La pantalla solo se usa para cargar pedidos |
62 | 48 | //var hojaRutaTemp = crearHojaRutaService.getHojaRuta(); |
63 | 49 | |
64 | - crearHojaRutaService.getPrecioCondicion().then( | |
65 | - function(res) { | |
66 | - $scope.precioCondiciones = res.data; | |
67 | - } | |
68 | - ); | |
69 | - | |
70 | 50 | crearHojaRutaService.getNumeroHojaRuta().then( |
71 | 51 | function(res) { |
72 | - $scope.puntoVenta = rellenar(res.data.sucursal, 4); | |
73 | - $scope.comprobante = rellenar(res.data.numeroHojaRuta, 8); | |
52 | + $scope.puntoVenta = $scope.rellenar(res.data.sucursal, 4); | |
53 | + $scope.comprobante = $scope.rellenar(res.data.numeroHojaRuta, 8); | |
74 | 54 | }, |
75 | 55 | function(err) { |
76 | 56 | focaModalService.alert('La terminal no esta configurada correctamente'); |
... | ... | @@ -87,7 +67,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
87 | 67 | // crearHojaRutaService |
88 | 68 | // .getArticulosByIdHojaRuta($scope.hojaRuta.id).then( |
89 | 69 | // function(res) { |
90 | - // $scope.articulosTabla = res.data; | |
70 | + // $scope.remitosTabla = res.data; | |
91 | 71 | // } |
92 | 72 | // ); |
93 | 73 | //TODO DOMICILIOS QUE SE CARGAN AL EDITAR NOTA DE PEDIDO |
... | ... | @@ -124,8 +104,8 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
124 | 104 | } else if(!$scope.hojaRuta.cliente.cod) { |
125 | 105 | focaModalService.alert('Ingrese Cliente'); |
126 | 106 | return; |
127 | - } else if(!$scope.hojaRuta.proveedor.codigo) { | |
128 | - focaModalService.alert('Ingrese Proveedor'); | |
107 | + } else if(!$scope.hojaRuta.transportista.codigo) { | |
108 | + focaModalService.alert('Ingrese Transportista'); | |
129 | 109 | return; |
130 | 110 | } else if(!$scope.hojaRuta.moneda.id) { |
131 | 111 | focaModalService.alert('Ingrese Moneda'); |
... | ... | @@ -144,7 +124,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
144 | 124 | } else if(!$scope.hojaRuta.domicilio.id) { |
145 | 125 | focaModalService.alert('Ingrese Domicilio'); |
146 | 126 | return; |
147 | - } else if($scope.articulosTabla.length === 0) { | |
127 | + } else if($scope.remitosTabla.length === 0) { | |
148 | 128 | focaModalService.alert('Debe cargar al menos un articulo'); |
149 | 129 | return; |
150 | 130 | } |
... | ... | @@ -157,8 +137,8 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
157 | 137 | idCliente: $scope.hojaRuta.cliente.cod, |
158 | 138 | nombreCliente: $scope.hojaRuta.cliente.nom, |
159 | 139 | cuitCliente: $scope.hojaRuta.cliente.cuit, |
160 | - idProveedor: $scope.hojaRuta.proveedor.codigo, | |
161 | 140 | idDomicilio: $scope.hojaRuta.domicilio.id, |
141 | + idProveedor: $scope.hojaRuta.transportista.codigo, | |
162 | 142 | idCotizacion: $scope.hojaRuta.cotizacion.ID, |
163 | 143 | cotizacion: $scope.hojaRuta.cotizacion.COTIZACION, |
164 | 144 | flete: $scope.hojaRuta.flete, |
... | ... | @@ -170,7 +150,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
170 | 150 | }; |
171 | 151 | crearHojaRutaService.crearHojaRuta(hojaRuta).then( |
172 | 152 | function(data) { |
173 | - hojaRutaBusinessService.addArticulos($scope.articulosTabla, | |
153 | + hojaRutaBusinessService.addArticulos($scope.remitosTabla, | |
174 | 154 | data.data.id, $scope.hojaRuta.cotizacion.COTIZACION); |
175 | 155 | focaSeguimientoService.guardarPosicion('crear nota pedido', ''); |
176 | 156 | var plazos = $scope.plazosPagos; |
... | ... | @@ -195,13 +175,13 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
195 | 175 | addCabecera('Cotizacion:', $scope.hojaRuta.cotizacion.COTIZACION); |
196 | 176 | $scope.hojaRuta.vendedor = {}; |
197 | 177 | $scope.hojaRuta.cliente = {}; |
198 | - $scope.hojaRuta.proveedor = {}; | |
199 | 178 | $scope.hojaRuta.domicilio = {}; |
179 | + $scope.hojaRuta.transportista = {}; | |
200 | 180 | $scope.hojaRuta.flete = null; |
201 | 181 | $scope.hojaRuta.fob = null; |
202 | 182 | $scope.hojaRuta.bomba = null; |
203 | 183 | $scope.hojaRuta.kilometros = null; |
204 | - $scope.articulosTabla = []; | |
184 | + $scope.remitosTabla = []; | |
205 | 185 | }, |
206 | 186 | function(error) { |
207 | 187 | focaModalService.alert('Hubo un error al crear la nota de pedido'); |
... | ... | @@ -240,7 +220,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
240 | 220 | sector: producto.sector, |
241 | 221 | sectorCodigo: producto.sector + '-' + producto.codigo, |
242 | 222 | descripcion: producto.descripcion, |
243 | - item: $scope.articulosTabla.length + 1, | |
223 | + item: $scope.remitosTabla.length + 1, | |
244 | 224 | nombre: producto.descripcion, |
245 | 225 | precio: parseFloat(producto.precio.toFixed(4)), |
246 | 226 | costoUnitario: producto.costo, |
... | ... | @@ -277,7 +257,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
277 | 257 | $scope.seleccionarProveedor = function() { |
278 | 258 | var modalInstance = $uibModal.open( |
279 | 259 | { |
280 | - ariaLabelledBy: 'Busqueda de Proveedor', | |
260 | + ariaLabelledBy: 'Busqueda de Transportista', | |
281 | 261 | templateUrl: 'modal-proveedor.html', |
282 | 262 | controller: 'focaModalProveedorCtrl', |
283 | 263 | size: 'lg', |
... | ... | @@ -290,8 +270,9 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
290 | 270 | ); |
291 | 271 | modalInstance.result.then( |
292 | 272 | function(proveedor) { |
293 | - $scope.hojaRuta.proveedor.codigo = proveedor.COD; | |
294 | - addCabecera('Proveedor:', proveedor.NOM); | |
273 | + console.info($scope.hojaRuta); | |
274 | + $scope.hojaRuta.transportista.codigo = proveedor.COD; | |
275 | + addCabecera('Transportista:', proveedor.NOM); | |
295 | 276 | }, function() { |
296 | 277 | |
297 | 278 | } |
... | ... | @@ -317,6 +298,34 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
317 | 298 | ); |
318 | 299 | }; |
319 | 300 | |
301 | + $scope.seleccionarRemito = function() { | |
302 | + var modalInstance = $uibModal.open( | |
303 | + { | |
304 | + ariaLabelledBy: 'Busqueda de Remito', | |
305 | + templateUrl: 'foca-modal-remito.html', | |
306 | + controller: 'focaModalRemitoController', | |
307 | + size: 'lg' | |
308 | + } | |
309 | + ); | |
310 | + modalInstance.result.then( | |
311 | + function(remito) { | |
312 | + var litros = 0; | |
313 | + for (var i = remito.articulosRemito.length - 1; i >= 0; i--) { | |
314 | + litros =+ remito.articulosRemito[i].cantidad; | |
315 | + } | |
316 | + | |
317 | + remito.litros = litros; | |
318 | + $scope.remitosTabla.push(remito); | |
319 | + console.info($scope.remitosTabla); | |
320 | + | |
321 | + | |
322 | + // TODO: Implementar carga remito | |
323 | + }, function() { | |
324 | + // funcion ejecutada cuando se cancela el modal | |
325 | + } | |
326 | + ); | |
327 | + }; | |
328 | + | |
320 | 329 | $scope.abrirModalDomicilios = function(cliente) { |
321 | 330 | var modalInstanceDomicilio = $uibModal.open( |
322 | 331 | { |
... | ... | @@ -354,7 +363,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
354 | 363 | |
355 | 364 | $scope.getTotal = function() { |
356 | 365 | var total = 0; |
357 | - var arrayTempArticulos = $scope.articulosTabla; | |
366 | + var arrayTempArticulos = $scope.remitosTabla; | |
358 | 367 | for (var i = 0; i < arrayTempArticulos.length; i++) { |
359 | 368 | total += arrayTempArticulos[i].precio * arrayTempArticulos[i].cantidad; |
360 | 369 | } |
... | ... | @@ -395,7 +404,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
395 | 404 | } |
396 | 405 | cabecera = 'Ingreso manual ' + plazosConcat.trim(); |
397 | 406 | } |
398 | - $scope.articulosTabla = []; | |
407 | + $scope.remitosTabla = []; | |
399 | 408 | addCabecera('Precios y condiciones:', cabecera); |
400 | 409 | }, function() { |
401 | 410 | |
... | ... | @@ -480,14 +489,14 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
480 | 489 | ); |
481 | 490 | modalInstance.result.then( |
482 | 491 | function(cotizacion) { |
483 | - var articulosTablaTemp = $scope.articulosTabla; | |
484 | - for(var i = 0; i < articulosTablaTemp.length; i++) { | |
485 | - articulosTablaTemp[i].precio = articulosTablaTemp[i].precio * | |
492 | + var remitosTablaTemp = $scope.remitosTabla; | |
493 | + for(var i = 0; i < remitosTablaTemp.length; i++) { | |
494 | + remitosTablaTemp[i].precio = remitosTablaTemp[i].precio * | |
486 | 495 | $scope.hojaRuta.cotizacion.COTIZACION; |
487 | - articulosTablaTemp[i].precio = articulosTablaTemp[i].precio / | |
496 | + remitosTablaTemp[i].precio = remitosTablaTemp[i].precio / | |
488 | 497 | cotizacion.COTIZACION; |
489 | 498 | } |
490 | - $scope.articulosTabla = articulosTablaTemp; | |
499 | + $scope.remitosTabla = remitosTablaTemp; | |
491 | 500 | $scope.hojaRuta.moneda = { |
492 | 501 | id: moneda.ID, |
493 | 502 | detalle: moneda.DETALLE, |
... | ... | @@ -520,13 +529,13 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
520 | 529 | } |
521 | 530 | delete $scope.articuloACargar.sectorCodigo; |
522 | 531 | console.info($scope.articuloACargar); |
523 | - $scope.articulosTabla.push($scope.articuloACargar); | |
532 | + $scope.remitosTabla.push($scope.articuloACargar); | |
524 | 533 | $scope.cargando = true; |
525 | 534 | } |
526 | 535 | }; |
527 | 536 | |
528 | 537 | $scope.quitarArticulo = function(key) { |
529 | - $scope.articulosTabla.splice(key, 1); | |
538 | + $scope.remitosTabla.splice(key, 1); | |
530 | 539 | }; |
531 | 540 | |
532 | 541 | $scope.editarArticulo = function(key, articulo) { |
... | ... | @@ -564,7 +573,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
564 | 573 | $scope.hojaRuta.flete = '0'; |
565 | 574 | $scope.hojaRuta.bomba = '0'; |
566 | 575 | $scope.hojaRuta.precioCondicion = ''; |
567 | - $scope.articulosTabla = []; | |
576 | + $scope.remitosTabla = []; | |
568 | 577 | $scope.hojaRuta.vendedor.nombre = ''; |
569 | 578 | $scope.hojaRuta.cliente = {nombre: ''}; |
570 | 579 | $scope.hojaRuta.domicilio = {dom: ''}; |
... | ... | @@ -600,6 +609,15 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
600 | 609 | articulo.precio = parseFloat(articulo.precio); |
601 | 610 | }; |
602 | 611 | |
612 | + $scope.rellenar = function(relleno, longitud) { | |
613 | + relleno = '' + relleno; | |
614 | + while (relleno.length < longitud) { | |
615 | + relleno = '0' + relleno; | |
616 | + } | |
617 | + | |
618 | + return relleno; | |
619 | + } | |
620 | + | |
603 | 621 | function addCabecera(label, valor) { |
604 | 622 | var propiedad = $filter('filter')($scope.cabecera, {label: label}, true); |
605 | 623 | if(propiedad.length === 1) { |
... | ... | @@ -616,14 +634,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', |
616 | 634 | } |
617 | 635 | } |
618 | 636 | |
619 | - function rellenar(relleno, longitud) { | |
620 | - relleno = '' + relleno; | |
621 | - while (relleno.length < longitud) { | |
622 | - relleno = '0' + relleno; | |
623 | - } | |
624 | - | |
625 | - return relleno; | |
626 | - } | |
637 | + | |
627 | 638 | } |
628 | 639 | ] |
629 | 640 | ) |
src/views/hoja-ruta.html
... | ... | @@ -87,13 +87,12 @@ |
87 | 87 | <table class="table tabla-articulo table-striped table-sm table-dark"> |
88 | 88 | <thead> |
89 | 89 | <tr class="d-flex"> |
90 | - <th class="">#</th> | |
91 | - <th class="col">Código</th> | |
92 | - <th class="col-4">Descripción</th> | |
93 | - <th class="col text-right">Cantidad</th> | |
94 | - <th class="col text-right">Precio Unitario</th> | |
95 | - <th class="col text-right">SubTotal</th> | |
96 | - <th class="text-right"> | |
90 | + <th class="col-auto">#</th> | |
91 | + <th class="col-2">Remito</th> | |
92 | + <th class="col">Cliente</th> | |
93 | + <th class="col">Dirección</th> | |
94 | + <th class="col-1">Litros</th> | |
95 | + <th class="col-auto"> | |
97 | 96 | <button |
98 | 97 | class="btn btn-outline-secondary selectable" |
99 | 98 | ng-click="show = !show; masMenos()" |
... | ... | @@ -111,67 +110,24 @@ |
111 | 110 | </i> |
112 | 111 | </button> |
113 | 112 | </th> |
113 | + </th> | |
114 | 114 | </tr> |
115 | 115 | </thead> |
116 | 116 | <tbody class="tabla-articulo-body"> |
117 | 117 | <tr |
118 | - ng-repeat="(key, articulo) in articulosTabla" | |
119 | - ng-show="show || key == (articulosTabla.length - 1)" | |
118 | + ng-repeat="(key, remito) in remitosTabla" | |
120 | 119 | class="d-flex" |
120 | + ng-show="show || key == 0" | |
121 | 121 | > |
122 | - <td ng-bind="key + 1"></td> | |
122 | + <td ng-bind="key + 1" class="col-auto"></td> | |
123 | 123 | <td |
124 | - class="col" | |
125 | - ng-bind="articulo.sector + '-' + articulo.codigo" | |
124 | + class="col-2" | |
125 | + ng-bind="rellenar(remito.sucursal, 4) + '-' + rellenar(remito.numeroRemito, 8)" | |
126 | 126 | ></td> |
127 | - <td | |
128 | - class="col-4" | |
129 | - ng-bind="articulo.descripcion" | |
130 | - ></td> | |
131 | - <td class="col text-right"> | |
132 | - <input | |
133 | - ng-show="articulo.editCantidad" | |
134 | - ng-model="articulo.cantidad" | |
135 | - class="form-control" | |
136 | - type="number" | |
137 | - min="1" | |
138 | - foca-focus="articulo.editCantidad" | |
139 | - ng-keypress="editarArticulo($event.keyCode, articulo)" | |
140 | - ng-focus="selectFocus($event)" | |
141 | - teclado-virtual | |
142 | - > | |
143 | - <i | |
144 | - class="selectable" | |
145 | - ng-click="cambioEdit(articulo, 'cantidad')" | |
146 | - ng-hide="articulo.editCantidad" | |
147 | - ng-bind="articulo.cantidad"> | |
148 | - </i> | |
149 | - </td> | |
150 | - <td class="col text-right"> | |
151 | - <input | |
152 | - ng-show="articulo.editPrecio" | |
153 | - ng-model="articulo.precio" | |
154 | - class="form-control" | |
155 | - type="number" | |
156 | - min="0" | |
157 | - step="0.0001" | |
158 | - foca-focus="articulo.editPrecio" | |
159 | - ng-keypress="editarArticulo($event.keyCode, articulo)" | |
160 | - ng-focus="selectFocus($event)" | |
161 | - teclado-virtual | |
162 | - > | |
163 | - <i | |
164 | - class="selectable" | |
165 | - ng-click="idLista == -1 && cambioEdit(articulo, 'precio')" | |
166 | - ng-hide="articulo.editPrecio" | |
167 | - ng-bind="articulo.precio | currency: hojaRuta.moneda.simbolo : 4"> | |
168 | - </i> | |
169 | - </td> | |
170 | - <td | |
171 | - class="col text-right" | |
172 | - ng-bind="(articulo.precio * articulo.cantidad) | currency: hojaRuta.moneda.simbolo"> | |
173 | - </td> | |
174 | - <td class="text-center"> | |
127 | + <th class="col" ng-bind="remito.cliente[0].NOM"></th> | |
128 | + <th class="col" ng-bind="remito.direccionStamp"></th> | |
129 | + <th class="col-1" ng-bind="remito.litros"></th> | |
130 | + <td class="text-center col-auto"> | |
175 | 131 | <button |
176 | 132 | class="btn btn-outline-secondary" |
177 | 133 | ng-click="quitarArticulo(key)" |
... | ... | @@ -182,100 +138,10 @@ |
182 | 138 | </tr> |
183 | 139 | </tbody> |
184 | 140 | <tfoot> |
185 | - <tr ng-show="!cargando" class="d-flex"> | |
186 | - <td | |
187 | - class="align-middle" | |
188 | - ng-bind="articulosTabla.length + 1" | |
189 | - ></td> | |
190 | - <td class="col"> | |
191 | - <input | |
192 | - class="form-control" | |
193 | - ng-model="articuloACargar.sectorCodigo" | |
194 | - readonly | |
195 | - > | |
196 | - </td> | |
197 | - <td class="col-4 tabla-articulo-descripcion"> | |
198 | - <input | |
199 | - class="form-control" | |
200 | - ng-model="articuloACargar.descripcion" | |
201 | - readonly | |
202 | - > | |
203 | - </td> | |
204 | - <td class="col text-right"> | |
205 | - <input | |
206 | - class="form-control" | |
207 | - type="number" | |
208 | - min="1" | |
209 | - ng-model="articuloACargar.cantidad" | |
210 | - foca-focus="!cargando" | |
211 | - esc-key="resetFilter()" | |
212 | - ng-keypress="agregarATabla($event.keyCode)" | |
213 | - ng-blur="parsearATexto(articuloACargar)" | |
214 | - teclado-virtual | |
215 | - > | |
216 | - </td> | |
217 | - <td class="col text-right"> | |
218 | - <input | |
219 | - class="form-control" | |
220 | - ng-value="articuloACargar.precio | currency: hojaRuta.moneda.simbolo : 4" | |
221 | - ng-show="idLista != -1" | |
222 | - readonly | |
223 | - > | |
224 | - <input | |
225 | - class="form-control" | |
226 | - type="number" | |
227 | - min="0" | |
228 | - step="0.0001" | |
229 | - ng-model="articuloACargar.precio" | |
230 | - esc-key="resetFilter()" | |
231 | - ng-keypress="agregarATabla($event.keyCode)" | |
232 | - ng-show="idLista == -1" | |
233 | - teclado-virtual | |
234 | - > | |
235 | - </td> | |
236 | - <td class="col text-right"> | |
237 | - <input | |
238 | - class="form-control" | |
239 | - ng-value="getSubTotal() | currency: hojaRuta.moneda.simbolo" | |
240 | - readonly | |
241 | - ></td> | |
242 | - <td class="text-center align-middle"> | |
243 | - <button | |
244 | - class="btn btn-outline-secondary" | |
245 | - ng-click="agregarATabla(13)" | |
246 | - > | |
247 | - <i class="fa fa-save"></i> | |
248 | - </button> | |
249 | - </td> | |
250 | - </tr> | |
251 | - <tr ng-show="cargando" class="d-flex"> | |
252 | - <td colspan="7" class="col-12"> | |
253 | - <input | |
254 | - placeholder="Seleccione Articulo" | |
255 | - class="form-control form-control-sm" | |
256 | - readonly | |
257 | - ng-click="seleccionarArticulo()" | |
258 | - /> | |
259 | - </td> | |
260 | - </tr> | |
261 | 141 | <tr class="d-flex"> |
262 | 142 | <td colspan="4" class="no-border-top"> |
263 | - <strong>Items:</strong> | |
264 | - <a ng-bind="articulosTabla.length"></a> | |
265 | - </td> | |
266 | - <td class="text-right ml-auto table-celda-total no-border-top"> | |
267 | - <h3>Total:</h3> | |
268 | - </td> | |
269 | - <td class="table-celda-total text-right no-border-top" colspan="1"> | |
270 | - <h3>{{getTotal() | currency: hojaRuta.moneda.simbolo}}</h3> | |
271 | - </td> | |
272 | - <td class="text-right no-border-top"> | |
273 | - <button | |
274 | - type="button" | |
275 | - class="btn btn-default btn-sm" | |
276 | - > | |
277 | - Totales | |
278 | - </button> | |
143 | + <strong>Remitos:</strong> | |
144 | + <a ng-bind="remitosTabla.length"></a> | |
279 | 145 | </td> |
280 | 146 | </tr> |
281 | 147 | </tfoot> |
... | ... | @@ -306,8 +172,8 @@ |
306 | 172 | </thead> |
307 | 173 | <tbody> |
308 | 174 | <tr |
309 | - ng-repeat="(key, articulo) in articulosTabla" | |
310 | - ng-show="show || key == articulosTabla.length - 1" | |
175 | + ng-repeat="(key, articulo) in remitosTabla" | |
176 | + ng-show="show || key == remitosTabla.length - 1" | |
311 | 177 | > |
312 | 178 | <td class="w-100 align-middle d-flex p-0"> |
313 | 179 | <div class="align-middle p-1"> |
... | ... | @@ -355,7 +221,7 @@ |
355 | 221 | <tr ng-show="!cargando" class="d-flex"> |
356 | 222 | <td |
357 | 223 | class="align-middle p-1" |
358 | - ng-bind="articulosTabla.length + 1" | |
224 | + ng-bind="remitosTabla.length + 1" | |
359 | 225 | ></td> |
360 | 226 | <td class="col p-0"> |
361 | 227 | <div class="d-flex"> |
... | ... | @@ -417,7 +283,7 @@ |
417 | 283 | <button |
418 | 284 | class="btn btn-outline-secondary selectable w-100" |
419 | 285 | ng-click="show = !show; masMenos()" |
420 | - ng-show="articulosTabla.length > 0" | |
286 | + ng-show="remitosTabla.length > 0" | |
421 | 287 | > |
422 | 288 | <i |
423 | 289 | class="fa fa-chevron-down" |
... | ... | @@ -437,7 +303,7 @@ |
437 | 303 | <tr class="d-flex"> |
438 | 304 | <td class="align-middle no-border-top" colspan="2"> |
439 | 305 | <strong>Cantidad Items:</strong> |
440 | - <a ng-bind="articulosTabla.length"></a> | |
306 | + <a ng-bind="remitosTabla.length"></a> | |
441 | 307 | </td> |
442 | 308 | <td class="text-right ml-auto table-celda-total no-border-top"> |
443 | 309 | <h3>Total:</h3> |