Commit 343c74ce352347e098fe3efc2600d415c0859df9

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

Merge branch 'master' into 'develop'

Master

See merge request !24
src/js/controller.js
... ... @@ -231,8 +231,8 @@ angular.module('focaBusquedaCliente')
231 231 $scope.seleccionarIva = function(key) {
232 232 if (key === 13) {
233 233 var parametrosModal = {
234   - searchText: $scope.cliente.iva.NOMBRE,
235 234 query: '/iva',
  235 + searchText: $scope.cliente.iva.NOMBRE,
236 236 columnas: [
237 237 {
238 238 propiedad: 'ID',
... ... @@ -333,28 +333,27 @@ angular.module('focaBusquedaCliente')
333 333 if ($scope.cliente.iva.ID == 1) {
334 334 datos = [
335 335 {
336   - id: 'A',
337   - nombre: 'Factura A'
  336 + ID: 'A',
  337 + NOMBRE: 'Factura A'
338 338 },
339 339 {
340   - id: 'M',
341   - nombre: 'Factura M'
  340 + ID: 'M',
  341 + NOMBRE: 'Factura M'
342 342 },
343 343 {
344   - id: 'R',
345   - nombre: 'Remito'
  344 + ID: 'R',
  345 + NOMBRE: 'Remito'
346 346 }
347 347 ];
348   -
349 348 } else {
350 349 datos = [
351 350 {
352   - id: 'B',
353   - nombre: 'Factura B'
  351 + ID: 'B',
  352 + NOMBRE: 'Factura B'
354 353 },
355 354 {
356   - id: 'R',
357   - nombre: 'Remito'
  355 + ID: 'R',
  356 + NOMBRE: 'Remito'
358 357 }
359 358 ];
360 359 }
... ... @@ -364,16 +363,16 @@ angular.module('focaBusquedaCliente')
364 363 size: 'md',
365 364 columnas: [
366 365 {
367   - propiedad: 'id',
368   - nombre: 'Codigo'
  366 + propiedad: 'ID',
  367 + NOMBRE: 'Codigo'
369 368 },
370 369 {
371   - propiedad: 'nombre',
372   - nombre: 'Factura'
  370 + propiedad: 'NOMBRE',
  371 + NOMBRE: 'Factura'
373 372 }
374 373 ],
375 374 }).then(function(res) {
376   - $scope.cliente.tipoFactura.NOMBRE = res.nombre;
  375 + $scope.cliente.tipoFactura = res;
377 376 });
378 377 }
379 378 };
... ... @@ -464,6 +463,7 @@ angular.module('focaBusquedaCliente')
464 463 };
465 464  
466 465 $scope.pasarCampoCuit = function(numeroCuit) {
  466 +
467 467 if (numeroCuit === 1 && $scope.cliente.cuit1.length === 2) {
468 468 $scope.cuitActivo = 2;
469 469 } else if ( numeroCuit === 2 && $scope.cliente.cuit2.length === 8) {