forked from elmau/empresa-libre
Fix - Agregar retencion de impuesto
This commit is contained in:
parent
7630059361
commit
7cc248da17
|
@ -764,7 +764,7 @@ class SATImpuestos(BaseModel):
|
||||||
tasa = float(values['tasa'])
|
tasa = float(values['tasa'])
|
||||||
tipo = 'T'
|
tipo = 'T'
|
||||||
if tasa < 0:
|
if tasa < 0:
|
||||||
tipo: 'R'
|
tipo = 'R'
|
||||||
|
|
||||||
row = {
|
row = {
|
||||||
'key': IMPUESTOS.get(values['impuesto']),
|
'key': IMPUESTOS.get(values['impuesto']),
|
||||||
|
@ -772,6 +772,7 @@ class SATImpuestos(BaseModel):
|
||||||
'tipo': tipo,
|
'tipo': tipo,
|
||||||
'tasa': abs(tasa),
|
'tasa': abs(tasa),
|
||||||
}
|
}
|
||||||
|
|
||||||
try:
|
try:
|
||||||
obj = SATImpuestos.create(**row)
|
obj = SATImpuestos.create(**row)
|
||||||
row['id'] = obj.id
|
row['id'] = obj.id
|
||||||
|
|
Loading…
Reference in New Issue