Commit ce26c30d512e1b6a904f76f1c4adef8e1a421cdc
1 parent
1c76f818a5
Exists in
master
and in
1 other branch
cantidad recibida para articulos
Showing
2 changed files
with
9 additions
and
3 deletions
Show diff stats
src/app/comprobantes/comprobantes.component.html
... | ... | @@ -90,7 +90,7 @@ |
90 | 90 | *ngIf="!articulo.input" |
91 | 91 | (click)="articulo.estado != 'rechazado' ? articulo.input = true : false" |
92 | 92 | > |
93 | - {{articulo.recibido ? articulo.recibido + '/' : ''}}{{articulo.CAN}} | |
93 | + {{articulo.cantidadRecibida != articulo.CAN ? articulo.cantidadRecibida + '/' : ''}}{{articulo.CAN}} | |
94 | 94 | </td> |
95 | 95 | <td *ngIf="articulo.input" class="col-5"> |
96 | 96 | <input |
src/app/comprobantes/comprobantes.component.ts
... | ... | @@ -37,7 +37,8 @@ export class ComprobantesComponent implements OnInit { |
37 | 37 | var lio = articulo.LI0.trim().toLocaleUpperCase().includes(this.filter.toLocaleUpperCase()); |
38 | 38 | var codigoBarras = articulo.codigoBarras == this.filter; |
39 | 39 | |
40 | - articulo.recibido && !articulo.estado ? articulo.estado = 'modificado' : false; | |
40 | + articulo.cantidadRecibida != articulo.CAN && !articulo.estado ? articulo.estado = 'modificado' : | |
41 | + false; | |
41 | 42 | |
42 | 43 | var estado = articulo.estado == this.estadoArticulos; |
43 | 44 | |
... | ... | @@ -87,6 +88,11 @@ export class ComprobantesComponent implements OnInit { |
87 | 88 | this.modalService.open(BusquedaComprobanteComponent).result.then(comprobante => { |
88 | 89 | |
89 | 90 | this.cabecera = comprobante.cabecera; |
91 | + | |
92 | + comprobante.cuerpo.forEach(articulo => { | |
93 | + articulo.cantidadRecibida = articulo.CAN; | |
94 | + }); | |
95 | + | |
90 | 96 | this.cuerpo = comprobante.cuerpo; |
91 | 97 | |
92 | 98 | this.getPaginaFiltro(); |
... | ... | @@ -99,7 +105,7 @@ export class ComprobantesComponent implements OnInit { |
99 | 105 | return; |
100 | 106 | } |
101 | 107 | articulo.input = false; |
102 | - articulo.recibido = articulo.tempRecibido; | |
108 | + articulo.cantidadRecibida = articulo.tempRecibido || articulo.CAN; | |
103 | 109 | } |
104 | 110 | |
105 | 111 | } |