Commit ebe4fe357b26a089f654e6b467b4f1260456b69b

Authored by Eric Fernandez
1 parent 3db891c88e
Exists in master

filtros fecha, filtro estado remito

src/js/controller.js
1 angular.module('focaLogisticaPedidoRuta') .controller('focaLogisticaPedidoRutaController', [ 1 angular.module('focaLogisticaPedidoRuta') .controller('focaLogisticaPedidoRutaController', [
2 '$scope', 'focaLogisticaPedidoRutaService', '$location', '$uibModal', '$filter', 2 '$scope', 'focaLogisticaPedidoRutaService', '$location', '$uibModal', '$filter',
3 'focaModalService', 'focaBotoneraLateralService', '$interval', 3 'focaModalService', 'focaBotoneraLateralService', '$interval',
4 function($scope, focaLogisticaPedidoRutaService, $location, $uibModal, $filter, 4 function($scope, focaLogisticaPedidoRutaService, $location, $uibModal, $filter,
5 focaModalService, focaBotoneraLateralService, $interval 5 focaModalService, focaBotoneraLateralService, $interval
6 ) { 6 ) {
7 $scope.actividad = 'Logistica'; 7 $scope.actividad = 'Logistica';
8 8
9 //Datos Pantalla 9 //Datos Pantalla
10 $scope.titulo = 'Logistica de Pedidos'; 10 $scope.titulo = 'Logistica de Pedidos';
11 $scope.botonera = ['Transportista']; 11 $scope.botonera = ['Transportista'];
12 var cabecera = ''; 12 var cabecera = '';
13 13 $scope.now = new Date();
14 $scope.idVendedor = 0; 14 $scope.idVendedor = 0;
15 $scope.marcadores = []; 15 $scope.marcadores = [];
16 $scope.vehiculos = []; 16 $scope.vehiculos = [];
17 getSeguimiento(); 17 getSeguimiento();
18 $scope.arrastrando = false; 18 $scope.arrastrando = false;
19 $scope.general = function() { 19 $scope.general = function() {
20 $scope.idVendedor = 0; 20 $scope.idVendedor = 0;
21 getSeguimiento(); 21 getSeguimiento();
22 }; 22 };
23 23
24 //SETEO BOTONERA LATERAL 24 //SETEO BOTONERA LATERAL
25 focaBotoneraLateralService.showSalir(true); 25 focaBotoneraLateralService.showSalir(true);
26 focaBotoneraLateralService.showPausar(false); 26 focaBotoneraLateralService.showPausar(false);
27 focaBotoneraLateralService.showGuardar(false); 27 focaBotoneraLateralService.showGuardar(false);
28 28
29 focaLogisticaPedidoRutaService.getVehiculosByIdUsuario().then(function(res) { 29 focaLogisticaPedidoRutaService.getVehiculosByIdUsuario().then(function(res) {
30 $scope.vehiculos = res.data; 30 $scope.vehiculos = res.data;
31 }); 31 });
32 32
33 $scope.general = function() { 33 $scope.general = function() {
34 $scope.idVendedor = 0; 34 $scope.idVendedor = 0;
35 getSeguimiento(); 35 getSeguimiento();
36 $scope.$broadcast('removeCabecera', cabecera); 36 $scope.$broadcast('removeCabecera', cabecera);
37 $scope.$broadcast('addCabecera',{ 37 $scope.$broadcast('addCabecera',{
38 label: 'General', 38 label: 'General',
39 valor: '' 39 valor: ''
40 }); 40 });
41 }; 41 };
42 42
43 $scope.cargar = function(idVehiculo, punto) { 43 $scope.cargar = function(idVehiculo, punto) {
44 var idRemito; 44 var idRemito;
45 if(punto === -1) { 45 if(punto === -1) {
46 idRemito = -1; 46 idRemito = -1;
47 }else { 47 }else {
48 idRemito = JSON.parse(punto).notaPedido.remito.id; 48 idRemito = JSON.parse(punto).notaPedido.remito.id;
49 } 49 }
50 var modalInstance = $uibModal.open( 50 var modalInstance = $uibModal.open(
51 { 51 {
52 ariaLabelledBy: 'Busqueda de Vehiculo', 52 ariaLabelledBy: 'Busqueda de Vehiculo',
53 templateUrl: 'foca-detalle-vehiculo.html', 53 templateUrl: 'foca-detalle-vehiculo.html',
54 controller: 'focaDetalleVehiculo', 54 controller: 'focaDetalleVehiculo',
55 size: 'lg', 55 size: 'lg',
56 resolve: { 56 resolve: {
57 idVehiculo: function() {return idVehiculo;}, 57 idVehiculo: function() {return idVehiculo;},
58 idRemito: function() {return idRemito;} 58 idRemito: function() {return idRemito;}
59 } 59 }
60 } 60 }
61 ); 61 );
62 modalInstance.result.then(function() { 62 modalInstance.result.then(function() {
63 }, function() { 63 }, function() {
64 }); 64 });
65 }; 65 };
66 66
67 $scope.quitarVehiculo = function(vehiculo) { 67 $scope.quitarVehiculo = function(vehiculo) {
68 focaModalService.confirm('Esta seguro que desea eliminar el vehículo ' + 68 focaModalService.confirm('Esta seguro que desea eliminar el vehículo ' +
69 vehiculo.codigo + '?').then(function() { 69 vehiculo.codigo + '?').then(function() {
70 eliminarVehiculo(vehiculo); 70 eliminarVehiculo(vehiculo);
71 }); 71 });
72 }; 72 };
73 73
74 $scope.hacerHojaRuta = function(vehiculo) { 74 $scope.hacerHojaRuta = function(vehiculo) {
75 var modalInstance = $uibModal.open( 75 var modalInstance = $uibModal.open(
76 { 76 {
77 ariaLabelledBy: 'Creación hoja ruta', 77 ariaLabelledBy: 'Creación hoja ruta',
78 templateUrl: 'foca-modal-crear-hoja-ruta.html', 78 templateUrl: 'foca-modal-crear-hoja-ruta.html',
79 controller: 'focaModalCrearHojaRuta', 79 controller: 'focaModalCrearHojaRuta',
80 size: 'lg', 80 size: 'lg',
81 resolve: { 81 resolve: {
82 idVehiculo: function() {return vehiculo.id;} 82 idVehiculo: function() {return vehiculo.id;}
83 } 83 }
84 } 84 }
85 ); 85 );
86 modalInstance.result.then(function() { 86 modalInstance.result.then(function() {
87 87
88 }, function() { 88 }, function() {
89 //usar cuando se cancela el modal 89 //usar cuando se cancela el modal
90 }); 90 });
91 }; 91 };
92 92
93 $scope.arrastra = function() { 93 $scope.arrastra = function() {
94 $scope.arrastrando = true; 94 $scope.arrastrando = true;
95 $scope.$digest(); 95 $scope.$digest();
96 }; 96 };
97 97
98 $scope.noArrastra = function() { 98 $scope.noArrastra = function() {
99 $scope.arrastrando = false; 99 $scope.arrastrando = false;
100 $scope.$digest(); 100 $scope.$digest();
101 }; 101 };
102 102
103 $scope.individual = function() { 103 $scope.individual = function() {
104 $scope.idVendedor = -1; 104 $scope.idVendedor = -1;
105 }; 105 };
106 106
107 $scope.mostrarDetalle = function() { 107 $scope.mostrarDetalle = function() {
108 $scope.detalle = true; 108 $scope.detalle = true;
109 }; 109 };
110 110
111 $scope.salir = function() { 111 $scope.salir = function() {
112 $location.path('/'); 112 $location.path('/');
113 }; 113 };
114 114
115 $scope.search = function(key) { 115 $scope.search = function() {
116 if (key === 13) { 116 getSeguimiento();
117 $scope.idVendedor = $scope.idVendedorInput;
118 getSeguimiento();
119 $scope.$broadcast('removeCabecera', 'General');
120 $scope.$broadcast('addCabecera', {
121 label: cabecera,
122 valor: $scope.idVendedorInput
123 });
124 }
125 }; 117 };
126 118
127 $scope.fecha = function() { 119 $scope.fecha = function() {
128 getSeguimiento(); 120 getSeguimiento();
129 }; 121 };
130 122
131 $scope.seleccionarTransportista = function() { 123 $scope.seleccionarTransportista = function() {
132 var modalInstance = $uibModal.open( 124 var modalInstance = $uibModal.open(
133 { 125 {
134 ariaLabelledBy: 'Busqueda de Transportista', 126 ariaLabelledBy: 'Busqueda de Transportista',
135 templateUrl: 'modal-proveedor.html', 127 templateUrl: 'modal-proveedor.html',
136 controller: 'focaModalProveedorCtrl', 128 controller: 'focaModalProveedorCtrl',
137 size: 'lg', 129 size: 'lg',
138 resolve: { 130 resolve: {
139 transportista: function() { 131 transportista: function() {
140 return true; 132 return true;
141 } 133 }
142 } 134 }
143 } 135 }
144 ); 136 );
145 modalInstance.result.then(function(transportista) { 137 modalInstance.result.then(function(transportista) {
146 $scope.seleccionarVehiculo(transportista.COD); 138 $scope.seleccionarVehiculo(transportista.COD);
147 }); 139 });
148 }; 140 };
149 141
150 $scope.seleccionarVehiculo = function(idTransportista) { 142 $scope.seleccionarVehiculo = function(idTransportista) {
151 var query = '/vehiculo/transportista/' + idTransportista; 143 var query = '/vehiculo/transportista/' + idTransportista;
152 var columnas = { 144 var columnas = {
153 nombre: ['Código', 'tractor', 'Semi', 'Capacidad'], 145 nombre: ['Código', 'tractor', 'Semi', 'Capacidad'],
154 propiedad: ['codigo', 'tractor', 'semi', 'capacidadTotalCisternas'] 146 propiedad: ['codigo', 'tractor', 'semi', 'capacidadTotalCisternas']
155 }; 147 };
156 var titulo = 'Búsqueda de vehiculos'; 148 var titulo = 'Búsqueda de vehiculos';
157 focaModalService.modal(columnas, query, titulo).then( 149 focaModalService.modal(columnas, query, titulo).then(
158 function(vehiculo) { 150 function(vehiculo) {
159 var existe = $filter('filter')($scope.vehiculos, {id: vehiculo.id}); 151 var existe = $filter('filter')($scope.vehiculos, {id: vehiculo.id});
160 if(existe.length) { 152 if(existe.length) {
161 focaModalService.alert('El vehiculo ya ha sido cargado'); 153 focaModalService.alert('El vehiculo ya ha sido cargado');
162 return; 154 return;
163 } 155 }
164 if(!vehiculo.cisternas.length) { 156 if(!vehiculo.cisternas.length) {
165 focaModalService.alert('El vehiculo no tiene cisternas'); 157 focaModalService.alert('El vehiculo no tiene cisternas');
166 return; 158 return;
167 } 159 }
168 $scope.vehiculos.push(vehiculo); 160 $scope.vehiculos.push(vehiculo);
169 }, function() { 161 }, function() {
170 // funcion ejecutada cuando se cancela el modal 162 // funcion ejecutada cuando se cancela el modal
171 }); 163 });
172 }; 164 };
173 165
174 function getSeguimiento() { 166 function getSeguimiento() {
175 var desde = new Date('1900/01/01'); 167 var desde = new Date('1900/01/01');
176 var hasta = new Date('2099/01/01'); 168 var hasta = new Date('2099/01/01');
177 if ($scope.now) { 169 if($scope.fechaDesde) {
178 var now = $scope.now; 170 var fechaDesde = $scope.fechaDesde;
179 desde = new Date(new Date(now.setHours(0)).setMinutes(0)); 171 desde = new Date(new Date(fechaDesde.setHours(0)).setMinutes(0));
180 desde = desde.setDate(desde.getDate() - 1);
181 desde = new Date(desde); 172 desde = new Date(desde);
182 } 173 }
174 if($scope.fechaHasta) {
175 var fechaHasta = $scope.fechaHasta;
176 hasta = new Date(new Date(fechaHasta.setHours(0)).setMinutes(0));
177 hasta = hasta.setDate(hasta.getDate() + 1);
178 hasta = new Date(hasta);
179 }
183 var datos = { 180 var datos = {
184 actividad: $scope.actividad, 181 actividad: $scope.actividad,
185 idUsuario: $scope.idVendedor, 182 idUsuario: $scope.idVendedor,
186 fechaDesde: desde, 183 fechaDesde: desde,
187 fechaHasta: hasta 184 fechaHasta: hasta,
185 asignacion: $scope.filtroEstado ? true : ($scope.filtroEstado !== undefined ?
186 false : undefined)
188 }; 187 };
189 188
190 $scope.datosBuscados = { 189 $scope.datosBuscados = {
191 actividad: $scope.actividad, 190 actividad: $scope.actividad,
192 individual: $scope.idVendedor ? true : false 191 individual: $scope.idVendedor ? true : false
193 }; 192 };
194 193
195 focaLogisticaPedidoRutaService.obtenerActividad(datos).then(function(datos) { 194 focaLogisticaPedidoRutaService.obtenerActividad(datos).then(function(datos) {
196 if(JSON.stringify(datos.data) !== JSON.stringify($scope.marcadores)) { 195 if(JSON.stringify(datos.data) !== JSON.stringify($scope.marcadores)) {
197 $scope.marcadores = datos.data; 196 $scope.marcadores = datos.data;
198 } 197 }
199 }); 198 });
200 } 199 }
201 200
202 function eliminarVehiculo(vehiculo) { 201 function eliminarVehiculo(vehiculo) {
203 focaLogisticaPedidoRutaService.getRemitos(vehiculo.id).then(function(res) { 202 focaLogisticaPedidoRutaService.getRemitos(vehiculo.id).then(function(res) {
204 if(!focaLogisticaPedidoRutaService.obtenerRemitosDeCarga(res.data).length) { 203 if(!focaLogisticaPedidoRutaService.obtenerRemitosDeCarga(res.data).length) {
205 $scope.vehiculos.splice($scope.vehiculos.indexOf(vehiculo), 1); 204 $scope.vehiculos.splice($scope.vehiculos.indexOf(vehiculo), 1);
206 }else { 205 }else {
207 focaModalService.alert('No ha sido posible eliminar el vehiculo porque ' + 206 focaModalService.alert('No ha sido posible eliminar el vehiculo porque ' +
208 'tiene remitos asociados').then(function() { 207 'tiene remitos asociados').then(function() {
209 $scope.hacerHojaRuta(vehiculo); 208 $scope.hacerHojaRuta(vehiculo);
210 }); 209 });
211 } 210 }
src/js/controllerDetalleVehiculo.js
1 angular.module('focaLogisticaPedidoRuta') 1 angular.module('focaLogisticaPedidoRuta')
2 .controller('focaDetalleVehiculo', 2 .controller('focaDetalleVehiculo',
3 ['$scope', 3 ['$scope',
4 '$uibModalInstance', 4 '$uibModalInstance',
5 'idVehiculo', 5 'idVehiculo',
6 'idRemito', 6 'idRemito',
7 'focaModalService', 7 'focaModalService',
8 '$filter', 8 '$filter',
9 'focaLogisticaPedidoRutaService', 9 'focaLogisticaPedidoRutaService',
10 function($scope, $uibModalInstance, idVehiculo, idRemito, focaModalService, $filter, 10 function($scope, $uibModalInstance, idVehiculo, idRemito, focaModalService, $filter,
11 focaLogisticaPedidoRutaService 11 focaLogisticaPedidoRutaService
12 ) { 12 ) {
13 //seteo variables 13 //seteo variables
14 $scope.idRemito = idRemito; 14 $scope.idRemito = idRemito;
15 $scope.articulos = []; 15 $scope.articulos = [];
16 $scope.vehiculo = {}; 16 $scope.vehiculo = {};
17 $scope.remito = {}; 17 $scope.remito = {};
18 $scope.aCargar = []; 18 $scope.aCargar = [];
19 var cisternaMovimientos = []; 19 var cisternaMovimientos = [];
20 focaLogisticaPedidoRutaService.obtenerVehiculoById(idVehiculo).then( 20 focaLogisticaPedidoRutaService.obtenerVehiculoById(idVehiculo).then(
21 function(res) { 21 function(res) {
22 $scope.vehiculo = res.data; 22 $scope.vehiculo = res.data;
23 } 23 }
24 ); 24 );
25 if(idRemito !== -1) { 25 if(idRemito !== -1) {
26 focaLogisticaPedidoRutaService.obtenerRemitoById(idRemito).then( 26 focaLogisticaPedidoRutaService.obtenerRemitoById(idRemito).then(
27 function(res) { 27 function(res) {
28 $scope.remito = res.data; 28 $scope.remito = res.data;
29 if($scope.remito.idUsuarioProceso) { 29 if($scope.remito.idUsuarioProceso) {
30 focaModalService.alert('El remito esta siendo cargado por otro usario'); 30 focaModalService.alert('Remito ya asignado');
31 $uibModalInstance.close(); 31 $uibModalInstance.close();
32 } 32 }
33 $scope.articulos = res.data.articulosRemito; 33 $scope.articulos = res.data.articulosRemito;
34 $scope.cambioArticulo($scope.articulos[0]); 34 $scope.cambioArticulo($scope.articulos[0]);
35 } 35 }
36 ); 36 );
37 } 37 }
38 $scope.aceptar = function() { 38 $scope.aceptar = function() {
39 $scope.cargando = true; 39 $scope.cargando = true;
40 var cisternaCargas = []; 40 var cisternaCargas = [];
41 for (var i = 0; i < $scope.vehiculo.cisternas.length; i++) { 41 for (var i = 0; i < $scope.vehiculo.cisternas.length; i++) {
42 delete $scope.vehiculo.cisternas[i].cisternaCarga.articulo; 42 delete $scope.vehiculo.cisternas[i].cisternaCarga.articulo;
43 cisternaCargas.push($scope.vehiculo.cisternas[i].cisternaCarga); 43 cisternaCargas.push($scope.vehiculo.cisternas[i].cisternaCarga);
44 } 44 }
45 var cisterna = { 45 var cisterna = {
46 cisternaMovimientos: cisternaMovimientos, 46 cisternaMovimientos: cisternaMovimientos,
47 cisternaCargas: cisternaCargas, 47 cisternaCargas: cisternaCargas,
48 idVehiculo: $scope.vehiculo.id 48 idVehiculo: $scope.vehiculo.id
49 }; 49 };
50 focaLogisticaPedidoRutaService.guardarCisternas(cisterna, $scope.remito.id) 50 focaLogisticaPedidoRutaService.guardarCisternas(cisterna, $scope.remito.id)
51 .then(function() { 51 .then(function() {
52 focaModalService.alert('Cisternas cargadas con éxito').then(function() { 52 focaModalService.alert('Cisternas cargadas con éxito').then(function() {
53 $scope.cargando = false; 53 $scope.cargando = false;
54 $uibModalInstance.close(); 54 $uibModalInstance.close();
55 }); 55 });
56 }).catch(function(error) { 56 }).catch(function(error) {
57 $scope.cargando = false; 57 $scope.cargando = false;
58 $uibModalInstance.close(); 58 $uibModalInstance.close();
59 if (error.status === 403.1) { 59 if (error.status === 403.1) {
60 focaModalService.alert('ERROR: El vehículo esta en uso'); 60 focaModalService.alert('ERROR: El vehículo esta en uso');
61 } 61 }
62 if(error.status === 403.2) { 62 if(error.status === 403.2) {
63 focaModalService.alert('ERROR: Otro usario ya cargó este remito'); 63 focaModalService.alert('ERROR: Otro usario ya cargó este remito');
64 return; 64 return;
65 } 65 }
66 focaModalService.alert('Hubo un error al cargar las cisternas'); 66 focaModalService.alert('Hubo un error al cargar las cisternas');
67 }); 67 });
68 }; 68 };
69 69
70 $scope.cancelar = function() { 70 $scope.cancelar = function() {
71 $uibModalInstance.close(); 71 $uibModalInstance.close();
72 }; 72 };
73 73
74 $scope.cargarACisternas = function(vehiculo) { 74 $scope.cargarACisternas = function(vehiculo) {
75 for(var i = 0; i < vehiculo.cisternas.length; i++) { 75 for(var i = 0; i < vehiculo.cisternas.length; i++) {
76 var cisterna = vehiculo.cisternas[i]; 76 var cisterna = vehiculo.cisternas[i];
77 var aCargar = parseFloat($scope.aCargar[i]); 77 var aCargar = parseFloat($scope.aCargar[i]);
78 //validaciones 78 //validaciones
79 if(!aCargar) { 79 if(!aCargar) {
80 continue; 80 continue;
81 } 81 }
82 if(aCargar > cisterna.disponible) { 82 if(aCargar > cisterna.disponible) {
83 focaModalService.alert('La cantidad cargada supera la capacidad de la' + 83 focaModalService.alert('La cantidad cargada supera la capacidad de la' +
84 'cisterna ' + cisterna.codigo); 84 'cisterna ' + cisterna.codigo);
85 return; 85 return;
86 } 86 }
87 //cargar 87 //cargar
88 if(cisterna.cisternaCarga.cantidad) { 88 if(cisterna.cisternaCarga.cantidad) {
89 cisterna.cisternaCarga.cantidad += aCargar; 89 cisterna.cisternaCarga.cantidad += aCargar;
90 }else { 90 }else {
91 cisterna.cisternaCarga.cantidad = aCargar; 91 cisterna.cisternaCarga.cantidad = aCargar;
92 cisterna.cisternaCarga.idProducto = $scope.articuloSeleccionado.idArticulo; 92 cisterna.cisternaCarga.idProducto = $scope.articuloSeleccionado.idArticulo;
93 } 93 }
94 cisterna.disponible = cisterna.capacidad - cisterna.cisternaCarga.cantidad; 94 cisterna.disponible = cisterna.capacidad - cisterna.cisternaCarga.cantidad;
95 95
96 cisterna.cisternaCarga.articulo = { 96 cisterna.cisternaCarga.articulo = {
97 DetArt: $scope.articuloSeleccionado.descripcion 97 DetArt: $scope.articuloSeleccionado.descripcion
98 }; 98 };
99 $filter('filter')($scope.articulos, {id: $scope.articuloSeleccionado.id})[0] 99 $filter('filter')($scope.articulos, {id: $scope.articuloSeleccionado.id})[0]
100 .cargado = true; 100 .cargado = true;
101 101
102 $scope.calcularPorcentaje(cisterna); 102 $scope.calcularPorcentaje(cisterna);
103 //Guardar 103 //Guardar
104 var now = new Date(); 104 var now = new Date();
105 var cisternaMovimiento = { 105 var cisternaMovimiento = {
106 fecha: now.toISOString().slice(0, 19).replace('T', ' '), 106 fecha: now.toISOString().slice(0, 19).replace('T', ' '),
107 cantidad: aCargar, 107 cantidad: aCargar,
108 metodo: 'carga', 108 metodo: 'carga',
109 idCisternaCarga: cisterna.cisternaCarga.id, 109 idCisternaCarga: cisterna.cisternaCarga.id,
110 idRemito: $scope.remito.id 110 idRemito: $scope.remito.id
111 }; 111 };
112 cisternaMovimientos.push(cisternaMovimiento); 112 cisternaMovimientos.push(cisternaMovimiento);
113 } 113 }
114 var articuloSiguiente = $scope.articulos.filter( 114 var articuloSiguiente = $scope.articulos.filter(
115 function(filter) { 115 function(filter) {
116 return filter.cargado !== true; 116 return filter.cargado !== true;
117 } 117 }
118 ); 118 );
119 if(articuloSiguiente.length > 0) { 119 if(articuloSiguiente.length > 0) {
120 $scope.cambioArticulo(articuloSiguiente[0]); 120 $scope.cambioArticulo(articuloSiguiente[0]);
121 } 121 }
122 $scope.aCargar = []; 122 $scope.aCargar = [];
123 }; 123 };
124 $scope.calcularPorcentaje = function(cisterna) { 124 $scope.calcularPorcentaje = function(cisterna) {
125 if(!cisterna.cisternaCarga.cantidad) { 125 if(!cisterna.cisternaCarga.cantidad) {
126 cisterna.cisternaCarga.cantidad = 0; 126 cisterna.cisternaCarga.cantidad = 0;
127 } 127 }
128 var porcentaje = (cisterna.cisternaCarga.cantidad * 100 / 128 var porcentaje = (cisterna.cisternaCarga.cantidad * 100 /
129 cisterna.capacidad) + '%'; 129 cisterna.capacidad) + '%';
130 var elementHtml = document.getElementById(cisterna.id); 130 var elementHtml = document.getElementById(cisterna.id);
131 if(elementHtml) { 131 if(elementHtml) {
132 elementHtml.style.width = porcentaje; 132 elementHtml.style.width = porcentaje;
133 } 133 }
134 }; 134 };
135 $scope.cambioArticulo = function(articulo) { 135 $scope.cambioArticulo = function(articulo) {
136 articulo.checked = true; 136 articulo.checked = true;
137 $scope.articuloSeleccionado = articulo; 137 $scope.articuloSeleccionado = articulo;
138 }; 138 };
139 $scope.actualizarArticulo = function () { 139 $scope.actualizarArticulo = function () {
140 $scope.articuloSeleccionado.cantidadCargada = 0; 140 $scope.articuloSeleccionado.cantidadCargada = 0;
141 for (var i = 0; i < $scope.aCargar.length; i++) { 141 for (var i = 0; i < $scope.aCargar.length; i++) {
142 $scope.articuloSeleccionado.cantidadCargada += 142 $scope.articuloSeleccionado.cantidadCargada +=
143 parseFloat($scope.aCargar[i]) || 0; 143 parseFloat($scope.aCargar[i]) || 0;
144 } 144 }
145 }; 145 };
146 $scope.tieneArticulosPendientes = function() { 146 $scope.tieneArticulosPendientes = function() {
147 var articulosDescargados = $scope.articulos.filter(function(filter) { 147 var articulosDescargados = $scope.articulos.filter(function(filter) {
148 return filter.cargado === true; 148 return filter.cargado === true;
149 }); 149 });
150 if(articulosDescargados.length === $scope.articulos.length) { 150 if(articulosDescargados.length === $scope.articulos.length) {
151 return false; 151 return false;
152 } 152 }
153 return true; 153 return true;
154 }; 154 };
155 }]); 155 }]);
156 156
src/js/osm-directive.js
1 angular.module('focaLogisticaPedidoRuta').directive('focaLogistica', function() { 1 angular.module('focaLogisticaPedidoRuta').directive('focaLogistica', function() {
2 return { 2 return {
3 restrict: 'E', 3 restrict: 'E',
4 link: function(scope, el, attrs) { 4 link: function(scope, el, attrs) {
5 var contenedor = document.createElement('div'); 5 var contenedor = document.createElement('div');
6 contenedor.className = 'border border-light rounded';
6 el.append(contenedor); 7 el.append(contenedor);
7 scope.map = L.map(contenedor).setView([attrs.latitud, attrs.longitud], attrs.zoom); 8 scope.map = L.map(contenedor).setView([attrs.latitud, attrs.longitud], attrs.zoom);
8 L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(scope.map); 9 L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(scope.map);
9 }, 10 },
10 controller: ['$scope', '$filter', function($scope, $filter) { 11 controller: ['$scope', '$filter', function($scope, $filter) {
11 $scope.markers = []; 12 $scope.markers = [];
12 $scope.$watch('marcadores', function() { 13 $scope.$watch('marcadores', function() {
13 for(var i in $scope.markers) { 14 for(var i in $scope.markers) {
14 $scope.map.removeLayer($scope.markers[i]); 15 $scope.map.removeLayer($scope.markers[i]);
15 } 16 }
16 $scope.markers = []; 17 $scope.markers = [];
17 18
18 angular.forEach($scope.marcadores, function(marcador) { 19 angular.forEach($scope.marcadores, function(marcador) {
19 var observacion = 20 var observacion =
20 'Vendedor: ' + marcador.notaPedido.idVendedor + ' - ' + 21 'Vendedor: ' + marcador.notaPedido.idVendedor + ' - ' +
21 ( 22 (
22 marcador.notaPedido.vendedor ? 23 marcador.notaPedido.vendedor ?
23 marcador.notaPedido.vendedor.NomVen : 24 marcador.notaPedido.vendedor.NomVen :
24 '' 25 ''
25 ) + '<br/>'; 26 ) + '<br/>';
26 observacion += 'Fecha: ' + 27 observacion += 'Fecha: ' +
27 $filter('date')(marcador.fecha.slice(0,10), 'dd/MM/yyyy') + ' ' + 28 $filter('date')(marcador.fecha.slice(0,10), 'dd/MM/yyyy') + ' ' +
28 marcador.fecha.slice(11,19) + '<br/>'; 29 marcador.fecha.slice(11,19) + '<br/>';
29 observacion += 'Remito Nº: ' + $filter('comprobante')([ 30 observacion += 'Remito Nº: ' + $filter('comprobante')([
30 marcador.notaPedido.remito.sucursal, 31 marcador.notaPedido.remito.sucursal,
31 marcador.notaPedido.remito.numeroRemito 32 marcador.notaPedido.remito.numeroRemito
32 ]) + '<br/>'; 33 ]) + '<br/>';
33 observacion += 'Cliente: ' + 34 observacion += 'Cliente: ' +
34 marcador.notaPedido.cliente.NOM + '<br/>'; 35 marcador.notaPedido.cliente.NOM + '<br/>';
35 36
36 // if($scope.parametros.individual) { 37 // if($scope.parametros.individual) {
37 observacion += 38 observacion +=
38 'Total: ' + $filter('currency')(marcador.notaPedido.remito.total, '$'); 39 'Total: ' + $filter('currency')(marcador.notaPedido.remito.total, '$');
39 observacion = 'Orden: ' + marcador.orden + '<br/>' + observacion; 40 observacion = 'Orden: ' + marcador.orden + '<br/>' + observacion;
40 41
41 if(marcador.distancia) { 42 if(marcador.distancia) {
42 observacion += '<br/>Distancia a casa central: ' + 43 observacion += '<br/>Distancia a casa central: ' +
43 marcador.distancia + 'km'; 44 marcador.distancia + 'km';
44 } 45 }
45 observacion += '<br/>'; 46 observacion += '<br/>';
46 observacion += '<i class="fa fa-map-marker fa-3x" aria-hidden="true"'+ 47 observacion += '<i class="fa fa-map-marker fa-3x" aria-hidden="true"'+
47 'class="form-control" ondragend="dropEnd()" ondragstart=\'drag(event, '+ 48 'class="form-control" ondragend="dropEnd()" ondragstart=\'drag(event, '+
48 JSON.stringify(marcador)+')\' draggable="true"></i>(Arrastrar icono)'; 49 JSON.stringify(marcador)+')\' draggable="true"></i>(Arrastrar icono)';
49 var icon; 50 var icon;
50 if(marcador.notaPedido.remito.idUsuarioProceso) { 51 if(marcador.notaPedido.remito.idUsuarioProceso) {
51 //Asignado AZUL 52 //Asignado ROJO
52 icon = new L.Icon({ 53 icon = new L.Icon({
53 iconUrl: 'img/marker-icon-2x-blue.png', 54 iconUrl: 'img/marker-icon-2x-red.png',
54 shadowUrl: 'img/marker-shadow.png', 55 shadowUrl: 'img/marker-shadow.png',
55 iconSize: [25, 41], 56 iconSize: [25, 41],
56 iconAnchor: [12, 41], 57 iconAnchor: [12, 41],
57 popupAnchor: [1, -34], 58 popupAnchor: [1, -34],
58 shadowSize: [41, 41] 59 shadowSize: [41, 41]
59 }); 60 });
60 }else { 61 }else {
61 //Sin asignar ROJO 62 //Sin asignar VERDE
62 icon = new L.Icon({ 63 icon = new L.Icon({
63 iconUrl: 'img/marker-icon-2x-red.png', 64 iconUrl: 'img/marker-icon-2x-green.png',
64 shadowUrl: 'img/marker-shadow.png', 65 shadowUrl: 'img/marker-shadow.png',
65 iconSize: [25, 41], 66 iconSize: [25, 41],
66 iconAnchor: [12, 41], 67 iconAnchor: [12, 41],
67 popupAnchor: [1, -34], 68 popupAnchor: [1, -34],
68 shadowSize: [41, 41] 69 shadowSize: [41, 41]
69 }); 70 });
70 } 71 }
71 $scope.markers.push( 72 $scope.markers.push(
72 L.marker([marcador.latitud, marcador.longitud], {icon: icon}) 73 L.marker([marcador.latitud, marcador.longitud], {icon: icon})
73 .addTo($scope.map) 74 .addTo($scope.map)
74 .bindPopup(observacion) 75 .bindPopup(observacion)
75 ); 76 );
76 77
77 $scope.markers[0].openPopup(); 78 $scope.markers[0].openPopup();
78 }); 79 });
79 }); 80 });
80 }], 81 }],
81 scope: { 82 scope: {
82 latitud: '=', 83 latitud: '=',
83 longitud: '=', 84 longitud: '=',
84 zoom: '=', 85 zoom: '=',
85 marcadores: '=', 86 marcadores: '=',
86 parametros: '=' 87 parametros: '='
87 } 88 }
88 }; 89 };
89 }); 90 });
90 91
src/views/foca-detalle-vehiculo.html
1 <div class="modal-header"> 1 <div class="modal-header">
2 <h4>Detalle de carga</h4> 2 <h4>Detalle de carga</h4>
3 Transportista <strong ng-bind="vehiculo.transportista.NOM"></strong> 3 Transportista <strong ng-bind="vehiculo.transportista.NOM"></strong>
4 Unidad <strong ng-bind="vehiculo.codigo"></strong> 4 Unidad <strong ng-bind="vehiculo.codigo"></strong>
5 Tractor <strong ng-bind="vehiculo.tractor"></strong> 5 Tractor <strong ng-bind="vehiculo.tractor"></strong>
6 <br> 6 <br>
7 <div ng-show="idRemito !== -1"> 7 <div ng-show="idRemito !== -1">
8 <span>Remito Nº</span> 8 <span>Remito Nº</span>
9 <strong ng-bind="[remito.sucursal, remito.numeroRemito] | comprobante"></strong> 9 <strong ng-bind="[remito.sucursal, remito.numeroRemito] | comprobante"></strong>
10 <span>, Fecha</span> 10 <span>, Fecha</span>
11 <strong ng-bind="remito.fechaRemito | date: 'dd/MM/yyyy HH:mm'"></strong> 11 <strong ng-bind="remito.fechaRemito | date: 'dd/MM/yyyy HH:mm'"></strong>
12 <span>, Cliente</span> 12 <span>, Cliente</span>
13 <strong ng-bind="remito.nombreCliente"></strong> 13 <strong ng-bind="remito.nombreCliente"></strong>
14 <span>, Domicilio entrega</span> 14 <span>, Domicilio entrega</span>
15 <strong ng-bind="remito.domicilioStamp"></strong> 15 <strong ng-bind="remito.domicilioStamp"></strong>
16 </div> 16 </div>
17 </div> 17 </div>
18 <div class="modal-body"> 18 <div class="modal-body">
19 <div> 19 <div>
20 <table class="table table-sm" ng-show="idRemito !== -1"> 20 <table class="table table-sm" ng-show="idRemito !== -1">
21 <thead> 21 <thead>
22 <tr> 22 <tr>
23 <th></th> 23 <th></th>
24 <th>Articulo</th> 24 <th>Articulo</th>
25 <th>Total</th> 25 <th>Total</th>
26 <th>Cargado</th> 26 <th>Cargado</th>
27 <th>Pendiente</th> 27 <th>Pendiente</th>
28 </tr> 28 </tr>
29 </thead> 29 </thead>
30 <tbody> 30 <tbody>
31 <tr ng-repeat="(key, articulo) in articulos"> 31 <tr ng-repeat="(key, articulo) in articulos">
32 <td><input 32 <td><input
33 type="radio" 33 type="radio"
34 name="articuloRadio" 34 name="articuloRadio"
35 id="{{'articulo' + articulo.id}}" 35 id="{{'articulo' + articulo.id}}"
36 ng-checked="articulo.checked" 36 ng-checked="articulo.checked"
37 ng-disabled="articulo.cargado" 37 ng-disabled="articulo.cargado"
38 ng-click="cambioArticulo(articulo)" 38 ng-click="cambioArticulo(articulo)"
39 ></td> 39 ></td>
40 <td ng-bind="articulo.descripcion"></td> 40 <td ng-bind="articulo.descripcion"></td>
41 <td ng-bind="articulo.cantidad"></td> 41 <td ng-bind="articulo.cantidad"></td>
42 <td ng-bind="articulo.cantidadCargada || 0"></td> 42 <td ng-bind="articulo.cantidadCargada || 0"></td>
43 <td ng-bind="articulo.cantidad - articulo.cantidadCargada"></td> 43 <td ng-bind="articulo.cantidad - articulo.cantidadCargada"></td>
44 </tr> 44 </tr>
45 </tbody> 45 </tbody>
46 </table> 46 </table>
47 <table class="table table-sm"> 47 <table class="table table-sm">
48 <thead> 48 <thead>
49 <tr> 49 <tr>
50 <th width="10%">Cisterna</th> 50 <th width="10%">Cisterna</th>
51 <th width="20%">Cantidad asignada</th> 51 <th width="20%">Cantidad asignada</th>
52 <th width="35%">Estado</th> 52 <th width="35%">Estado</th>
53 <th>Articulo cargado</th> 53 <th>Articulo cargado</th>
54 </tr> 54 </tr>
55 </thead> 55 </thead>
56 <tbody> 56 <tbody>
57 <tr ng-repeat="(key, cisterna) in vehiculo.cisternas"> 57 <tr ng-repeat="(key, cisterna) in vehiculo.cisternas">
58 <td ng-bind="cisterna.codigo"></td> 58 <td ng-bind="cisterna.codigo"></td>
59 <td><input 59 <td><input
60 class="form-control" 60 class="form-control"
61 foca-tipo-input 61 foca-tipo-input
62 foca-teclado 62 foca-teclado
63 placeholder="A cargar..." 63 placeholder="A cargar..."
64 ng-model="aCargar[key]" 64 ng-model="aCargar[key]"
65 ng-disabled="(articuloSeleccionado.idArticulo !== cisterna.cisternaCarga.idProducto && 65 ng-disabled="(articuloSeleccionado.idArticulo !== cisterna.cisternaCarga.idProducto &&
66 cisterna.cisternaCarga.idProducto) || !tieneArticulosPendientes() 66 cisterna.cisternaCarga.idProducto) || !tieneArticulosPendientes()
67 || articuloSeleccionado.cantidad > cisterna.disponible" 67 || articuloSeleccionado.cantidad > cisterna.disponible"
68 ng-change="actualizarArticulo()" 68 ng-change="actualizarArticulo()"
69 > 69 >
70 </td> 70 </td>
71 <td><div class="progress foca-alto-progress pl-0 pr-0 mt-1"> 71 <td><div class="progress foca-alto-progress pl-0 pr-0 mt-1">
72 <strong 72 <strong
73 class="mt-2 col-4 text-center position-absolute" 73 class="mt-2 col-4 text-center position-absolute"
74 ng-bind="(cisterna.cisternaCarga.cantidad || 0) + '/' + (cisterna.capacidad)"> 74 ng-bind="(cisterna.cisternaCarga.cantidad || 0) + '/' + (cisterna.capacidad)">
75 </strong> 75 </strong>
76 <div 76 <div
77 id="{{cisterna.id}}" 77 id="{{cisterna.id}}"
78 class="progress-bar" 78 class="progress-bar"
79 role="progressbar" 79 role="progressbar"
80 aria-valuemin="0" 80 aria-valuemin="0"
81 aria-valuemax="{{cisterna.capacidad}}" 81 aria-valuemax="{{cisterna.capacidad}}"
82 ng-style="{'width':'{{calcularPorcentaje(cisterna)}}'}"> 82 ng-style="{'width':'{{calcularPorcentaje(cisterna)}}'}">
83 </div> 83 </div>
84 </div> 84 </div>
85 </td> 85 </td>
86 <td ng-bind="cisterna.cisternaCarga.articulo.DetArt || 'Sin articulo'"></td> 86 <td ng-bind="cisterna.cisternaCarga.articulo.DetArt || 'Sin asignar'"></td>
87 </tr> 87 </tr>
88 </tbody> 88 </tbody>
89 </table> 89 </table>
90 <div class="col-12 aling-end"> 90 <div class="col-12 aling-end">
91 <button 91 <button
92 class="form-control btn btn-success" 92 class="form-control btn btn-success"
93 ladda="cargando" 93 ladda="cargando"
94 data-spinner-color="#FF0000" 94 data-spinner-color="#FF0000"
95 type="button" 95 type="button"
96 ng-disabled="!articuloSeleccionado || articuloSeleccionado.cantidad - 96 ng-disabled="!articuloSeleccionado || articuloSeleccionado.cantidad -
97 articuloSeleccionado.cantidadCargada !== 0 || !tieneArticulosPendientes()" 97 articuloSeleccionado.cantidadCargada !== 0 || !tieneArticulosPendientes()"
98 ng-class="{'btn-light': !articuloSeleccionado || articuloSeleccionado.cantidad - 98 ng-class="{'btn-light': !articuloSeleccionado || articuloSeleccionado.cantidad -
99 articuloSeleccionado.cantidadCargada !== 0 || !tieneArticulosPendientes()}" 99 articuloSeleccionado.cantidadCargada !== 0 || !tieneArticulosPendientes()}"
100 ng-click="cargarACisternas(vehiculo)"> 100 ng-click="cargarACisternas(vehiculo)">
101 Aplicar distribución de cargas 101 Aplicar distribución de cargas
102 </button> 102 </button>
103 </div> 103 </div>
104 </div> 104 </div>
105 </div> 105 </div>
106 <div class="modal-footer py-1"> 106 <div class="modal-footer py-1">
107 <button 107 <button
108 class="btn btn-sm btn-secondary" 108 class="btn btn-sm btn-secondary"
109 ladda="cargando" 109 ladda="cargando"
110 type="button" 110 type="button"
111 ng-click="cancelar()">Cancelar</button> 111 ng-click="cancelar()">Cancelar</button>
112 <button 112 <button
113 class="btn btn-sm btn-primary" 113 class="btn btn-sm btn-primary"
114 ladda="cargando" 114 ladda="cargando"
115 type="button" 115 type="button"
116 ng-click="aceptar()" 116 ng-click="aceptar()"
117 ng-disabled="tieneArticulosPendientes() || idRemito === -1">Cargar</button> 117 ng-disabled="tieneArticulosPendientes() || idRemito === -1">Cargar</button>
118 </div> 118 </div>
119 119
src/views/foca-logistica-pedido-ruta.html
1 <div class="foca-logistica-pedido-ruta" id="scope"> 1 <div class="foca-logistica-pedido-ruta" id="scope">
2 <div class="row"> 2 <div class="row">
3 <foca-cabecera-facturador 3 <foca-cabecera-facturador
4 titulo="titulo" 4 titulo="titulo"
5 fecha="now" 5 fecha="now"
6 class="mb-0 col-lg-12" 6 class="mb-0 col-lg-12"
7 ></foca-cabecera-facturador> 7 ></foca-cabecera-facturador>
8 </div> 8 </div>
9 <div class="row px-5 py-2 botonera-secundaria"> 9 <div class="row px-5 py-2 botonera-secundaria">
10 <div class="col-12"> 10 <div class="col-12">
11 <foca-botonera-facturador botones="botonera" extra="5" class="row"></foca-botonera-facturador> 11 <foca-botonera-facturador botones="botonera" extra="5" class="row"></foca-botonera-facturador>
12 </div> 12 </div>
13 </div> 13 </div>
14 <div class="row"> 14 <div class="row">
15 <div class="offset-1 col-9"> 15 <div class="offset-1 col-9">
16 <foca-logistica 16 <foca-logistica
17 latitud="-32.89214159952345" 17 latitud="-32.89214159952345"
18 longitud="-68.84572999101856" 18 longitud="-68.84572999101856"
19 zoom="14" 19 zoom="14"
20 marcadores="marcadores" 20 marcadores="marcadores"
21 parametros= "datosBuscados" 21 parametros= "datosBuscados"
22 /> 22 />
23 </div> 23 </div>
24 <div class="col-2 pl-0"> 24 <div class="col-2 pl-0">
25 <strong>Filtros: </strong>
26 <br>
27 <span>Fecha Desde</span>
25 <input 28 <input
26 type="text" 29 type="text"
27 readonly 30 readonly
28 ng-model="now" 31 ng-model="fechaDesde"
29 class="form-control" 32 class="form-control form-control-sm"
30 uib-datepicker-popup="dd/MM/yyyy" 33 uib-datepicker-popup="dd/MM/yyyy"
31 show-button-bar="false" 34 show-button-bar="false"
32 is-open="datepickerOpen" 35 is-open="fechaDesdeOpen"
33 on-open-focus="false" 36 on-open-focus="false"
34 ng-focus="datepickerOpen = true" 37 ng-focus="fechaDesdeOpen = true"
35 datepicker-options="dateOptions" 38 ng-change="search()"
36 /> 39 />
37 <button 40 <span>Fecha Hasta</span>
41 <input
42 type="text"
43 readonly
44 ng-model="fechaHasta"
45 class="form-control form-control-sm"
46 uib-datepicker-popup="dd/MM/yyyy"
47 show-button-bar="false"
48 is-open="fechaHastaOpen"
49 on-open-focus="false"
50 ng-focus="fechaHastaOpen = true"
51 ng-change="search()"
52 />
53 <!-- TODO: descomentar cuando se quite definitivamente -->
54 <!-- <button
38 type="button" 55 type="button"
39 ng-class="{'active': idVendedor == 0}" 56 ng-class="{'active': idVendedor == 0}"
40 class="btn col-12 my-1" 57 class="btn col-12 my-1"
41 ng-click="general()" 58 ng-click="general()"
42 >General</button> 59 >General</button>
43 <button 60 <button
44 type="button" 61 type="button"
45 ng-class="{'active': idVendedor != 0}" 62 ng-class="{'active': idVendedor != 0}"
46 class="btn col-12 my-1" 63 class="btn col-12 my-1"
47 ng-click="individual()" 64 ng-click="individual()"
48 >Individual</button> 65 >Individual</button>
49 <div class="form-group" ng-show="idVendedor == -1"> 66 <div class="form-group" ng-show="idVendedor == -1">
50 <input 67 <input
51 type="text" 68 type="text"
52 placeholder="Vendedor" 69 placeholder="Vendedor"
53 class="form-control" 70 class="form-control"
54 ng-model="idVendedorInput" 71 ng-model="idVendedorInput"
55 ng-keypress="search($event.keyCode)" 72 ng-keypress="search($event.keyCode)"
56 foca-focus="idVendedor == -1" 73 foca-focus="idVendedor == -1"
57 > 74 >
75 </div> -->
76 <div class="custom-control custom-radio">
77 <input
78 type="radio"
79 class="custom-control-input"
80 id="idTodos"
81 name="filtro"
82 ng-model="filtroEstado"
83 ng-change="search()"
84 checked>
85 <label class="custom-control-label pb-3" for="idTodos"></label>
86 <img src="img/marker-icon-grey.png">
87 <strong>Todos</strong>
58 </div> 88 </div>
59 <div> 89 <div class="custom-control custom-radio">
60 <img src="img/marker-icon-blue.png"> 90 <input
61 <strong>Asignado</strong> 91 type="radio"
62 <br> 92 class="custom-control-input"
63 <img src="img/marker-icon-red.png"> 93 id="idSinAsignar"
94 name="filtro"
95 ng-model="filtroEstado"
96 ng-change="search()"
97 ng-value="false">
98 <label class="custom-control-label pb-3" for="idSinAsignar"></label>
99 <img src="img/marker-icon-green.png">
64 <strong>Sin asignar</strong> 100 <strong>Sin asignar</strong>
65 </div> 101 </div>
102 <div class="custom-control custom-radio">
103 <input
104 type="radio"
105 class="custom-control-input"
106 id="idAsignado"
107 name="filtro"
108 ng-model="filtroEstado"
109 ng-change="search()"
110 ng-value="true">
111 <label class="custom-control-label pb-3" for="idAsignado"></label>
112 <img src="img/marker-icon-red.png">
113 <strong>Asignado</strong>
114 </div>
66 </div> 115 </div>
67 <div class="row"> 116 <div class="row">
68 <div 117 <div
69 class="container col-auto" 118 class="container col-auto"
70 ng-repeat="vehiculo in vehiculos" 119 ng-repeat="vehiculo in vehiculos"
71 ng-click="mostrarDetalleVehiculo(vehiculo)" 120 ng-click="mostrarDetalleVehiculo(vehiculo)"
72 > 121 >
73 <div> 122 <div>
74 <div class="col-md-3 col-sm-6"> 123 <div class="col-md-3 col-sm-6">
75 <div class="progress-circle" ng-class="{'arrastrando': arrastrando}"> 124 <div class="progress-circle" ng-class="{'arrastrando': arrastrando}">
76 <span class="progress-left"> 125 <span class="progress-left">
77 <span class="progress-bar"></span> 126 <span class="progress-bar"></span>
78 </span> 127 </span>
79 <span class="progress-right"> 128 <span class="progress-right">
80 <span class="progress-bar"></span> 129 <span class="progress-bar"></span>
81 </span> 130 </span>
82 <div class="progress-value">{{vehiculo.codigo}}</div> 131 <div class="progress-value">{{vehiculo.codigo}}</div>
83 </div> 132 </div>
84 </div> 133 </div>
85 <div class="row ml-2"> 134 <div class="row ml-2">
86 <div class="col-3 position-absolute"> 135 <div class="col-3 position-absolute">
87 <img 136 <img
88 src="img/hojaRutaVolante.png" 137 src="img/hojaRutaVolante.png"
89 width="100%"> 138 width="100%">
90 </div> 139 </div>
91 <div class="col-3" 140 <div class="col-3"
92 uib-tooltip="Confeccionar hoja de ruta" 141 uib-tooltip="Confeccionar hoja de ruta"
93 ng-click="hacerHojaRuta(vehiculo)"></div> 142 ng-click="hacerHojaRuta(vehiculo)"></div>
94 <div class="col-3"> 143 <div class="col-3">
95 <i 144 <i
96 class="fa fa-eye fa-2x" 145 class="fa fa-eye fa-2x"
97 uib-tooltip="Ver cisternas" 146 uib-tooltip="Ver cisternas"
98 ng-click="cargar(vehiculo.id, -1)"> 147 ng-click="cargar(vehiculo.id, -1)">
99 </i> 148 </i>
100 </div> 149 </div>
101 <div class="col-3 ml-2"> 150 <div class="col-3 ml-2">
102 <i 151 <i
103 class="fa fa-trash fa-2x" 152 class="fa fa-trash fa-2x"
104 uib-tooltip="Eliminar vehiculo" 153 uib-tooltip="Eliminar vehiculo"
105 ng-click="quitarVehiculo(vehiculo)"></i> 154 ng-click="quitarVehiculo(vehiculo)"></i>
106 </div> 155 </div>
107 </div> 156 </div>
108 <div 157 <div
109 class="ml-1 border border-dark text-center" 158 class="ml-1 border border-dark text-center"
110 ng-show="arrastrando" 159 ng-show="arrastrando"
111 id="{{vehiculo.id}}" 160 id="{{vehiculo.id}}"
112 ondrop="drop(event)" 161 ondrop="drop(event)"
113 ondragover="allowDrop(event)" 162 ondragover="allowDrop(event)"
114 >Soltar acá</div> 163 >Soltar acá</div>
115 </div> 164 </div>
116 </div> 165 </div>
117 </div> 166 </div>
118 </div> 167 </div>
119 </div> 168 </div>
120 169