diff --git a/src/js/controller.js b/src/js/controller.js index 3bddc38..368d50b 100644 --- a/src/js/controller.js +++ b/src/js/controller.js @@ -26,6 +26,9 @@ angular.module('focaLogisticaPedidoRuta') .controller('focaLogisticaPedidoRutaCo focaBotoneraLateralService.showPausar(false); focaBotoneraLateralService.showGuardar(false); + focaLogisticaPedidoRutaService.getVehiculosByIdUsuario().then(function(res) { + $scope.vehiculos = res.data; + }); $scope.general = function() { $scope.idVendedor = 0; diff --git a/src/js/service.js b/src/js/service.js index 1c1b6e8..d670392 100644 --- a/src/js/service.js +++ b/src/js/service.js @@ -65,6 +65,9 @@ angular.module('focaLogisticaPedidoRuta') } } return remitosRes; + }, + getVehiculosByIdUsuario: function() { + return $http.get(API_ENDPOINT.URL + '/vehiculo/usuario/' + this.idUsuario); } }; }]);