Commit 62ccc3b54b93128118fe021e836d4763f17fa0f2

Authored by Jose Pinto
1 parent 34091f2d68
Exists in master and in 1 other branch develop

Codigo solo editable si es nuevo

src/js/controllerCisterna.js
... ... @@ -4,11 +4,12 @@ angular.module('focaAbmVehiculo')
4 4 'focaModalService', 'focaBotoneraLateralService', '$timeout', '$window',
5 5 function($scope, focaAbmVehiculoService, $routeParams, $location, $uibModal,
6 6 focaModalService, focaBotoneraLateralService, $timeout, $window) {
  7 + $scope.nuevo = ($routeParams.id > 0) ? false : true;
7 8 $scope.editar = false;
8 9 $scope.now = new Date();
9 10 $scope.cisterna = {};
10 11  
11   - $scope.focused = 1;
  12 + $scope.focused = $scope.nuevo ? 1 : 2;
12 13 $scope.next = function(key) {
13 14 if (key === 13) $scope.focused++;
14 15 };
src/views/foca-abm-cisterna-item.html
... ... @@ -18,6 +18,7 @@
18 18 ng-keypress="next($event.keyCode)"
19 19 foca-focus="focused == 1"
20 20 ng-focus="focused = 1"
  21 + ng-disabled="!nuevo"
21 22 teclado-virtual
22 23 />
23 24 </div>
src/views/foca-abm-vehiculos-item.html
... ... @@ -21,6 +21,7 @@
21 21 foca-focus="focused == 1"
22 22 ng-focus="focused = 1"
23 23 ng-keypress="next($event.keyCode)"
  24 + ng-disabled="!nuevo"
24 25 />
25 26 </div>
26 27 </div>