Commit 2ad52c8418a9bcbe8ccfe41d1bdc12e2c41a6d3e
Exists in
master
and in
2 other branches
Merge branch 'master' into 'develop'
Master See merge request !36
Showing
1 changed file
 
Show diff stats
src/js/controller.js
| ... | ... | @@ -65,11 +65,11 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', | 
| 65 | 65 | console.info(err); | 
| 66 | 66 | } | 
| 67 | 67 | ); | 
| 68 | - | |
| 68 | + setearFecha(new Date()); | |
| 69 | 69 | $scope.inicial = angular.copy($scope.hojaRuta); | 
| 70 | 70 | } | 
| 71 | 71 | |
| 72 | - $scope.$watch('hojaRuta', function(newValue, oldValue) { | |
| 72 | + $scope.$watch('hojaRuta', function(newValue) { | |
| 73 | 73 | focaBotoneraLateralService.setPausarData({ | 
| 74 | 74 | label: 'hojaRuta', | 
| 75 | 75 | val: newValue | 
| ... | ... | @@ -332,6 +332,15 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', | 
| 332 | 332 | }); | 
| 333 | 333 | }; | 
| 334 | 334 | |
| 335 | + function setearFecha(fecha) { | |
| 336 | + $timeout(function() { | |
| 337 | + $scope.$broadcast('addCabecera', { | |
| 338 | + label: 'Fecha de entrega: ', | |
| 339 | + valor: fecha.toLocaleDateString() | |
| 340 | + }); | |
| 341 | + }); | |
| 342 | + } | |
| 343 | + | |
| 335 | 344 | $scope.seleccionarDatosExtra = function() { | 
| 336 | 345 | var datosHojaRuta = $scope.hojaRuta.datosExtra; | 
| 337 | 346 | var modalInstance = $uibModal.open( | 
| ... | ... | @@ -367,7 +376,7 @@ angular.module('focaCrearHojaRuta') .controller('hojaRutaCtrl', | 
| 367 | 376 | }); | 
| 368 | 377 | }); | 
| 369 | 378 | }; | 
| 370 | - | |
| 379 | + | |
| 371 | 380 | $scope.verProductosRemito = function(idRemito) { | 
| 372 | 381 | var parametrosModal = { | 
| 373 | 382 | titulo: 'Articulos remito', |