Skip to content

Commit

Permalink
Merge branch '12.0' into 12.0-br_pos_nfce
Browse files Browse the repository at this point in the history
  • Loading branch information
danimaribeiro authored Nov 6, 2020
2 parents 9d630f5 + e10bb60 commit 157c660
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion br_cnab/febraban/cnab_240/bancos/itau.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
# KMEE - www.kmee.com.br
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).


from ..cnab_240 import Cnab240
from datetime import datetime
from decimal import Decimal


class Itau240(Cnab240):
Expand Down Expand Up @@ -42,6 +42,10 @@ def _prepare_segmento(self, line):
vals['codigo_multa'] = int(vals['codigo_multa'])
vals['data_multa'] = str(vals['data_multa']).zfill(8)
vals['juros_multa'] = vals['juros_multa']
if vals.get('juros_mora_taxa') > 0.0:
multa_mes = vals['valor_titulo'] * (vals.get('juros_mora_taxa') / 100)
dia = round(multa_mes / 30, 2) or 0.01;
vals['juros_mora_taxa'] = Decimal(str(dia)).quantize(Decimal('1.00'))
return vals

def dv_nosso_numero(self, agencia, conta, carteira, nosso_numero):
Expand Down

0 comments on commit 157c660

Please sign in to comment.