diff --git a/src/js/controllerCisterna.js b/src/js/controllerCisterna.js index 28cfbdd..8ab9fbb 100644 --- a/src/js/controllerCisterna.js +++ b/src/js/controllerCisterna.js @@ -4,7 +4,7 @@ angular.module('focaAbmVehiculo') 'focaModalService', 'focaBotoneraLateralService', '$timeout', '$window', function($scope, focaAbmVehiculoService, $routeParams, $location, $uibModal, focaModalService, focaBotoneraLateralService, $timeout, $window) { - $scope.nuevo = ($routeParams.id > 0) ? false : true; + $scope.nuevo = ($routeParams.idx > -1) ? false : true; $scope.editar = false; $scope.now = new Date(); $scope.cisterna = {}; @@ -25,7 +25,7 @@ angular.module('focaAbmVehiculo') }); if($routeParams.idx !== -1) { - $scope.cisterna = [$routeParams.idx] + $scope.cisterna = [$routeParams.idx]; focaAbmVehiculoService .getCisternas($routeParams.idVehiculo) .then(function(res) {