From 16ffeedef8a018b20db58d0eb5143bc15b70a4cf Mon Sep 17 00:00:00 2001 From: Luigi Date: Tue, 9 Apr 2019 10:08:14 -0300 Subject: [PATCH] Arreglo moneda por defecto --- src/js/controller.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/js/controller.js b/src/js/controller.js index 8dcf053..a8977be 100644 --- a/src/js/controller.js +++ b/src/js/controller.js @@ -50,18 +50,18 @@ angular.module('focaCrearNotaPedido') .controller('notaPedidoCtrl', } //Trabajo con la cotización más reciente, por eso uso siempre la primera '[0]' - /*crearNotaPedidoService.getCotizacionByIdMoneda(1).then(function(res) { + crearNotaPedidoService.getCotizacionByIdMoneda(1).then(function(res) { var monedaPorDefecto = res.data[0]; - $scope.inicial.cotizacion = Object.assign( {moneda: monedaPorDefecto}, monedaPorDefecto.cotizaciones[0] ); $scope.notaPedido.cotizacion = $scope.inicial.cotizacion; - });*/ + $timeout(function() {getLSNotaPedido();}); + }); init(); - $timeout(function() {getLSNotaPedido();}); + } function init() { -- 1.9.1