Skip to content

Commit

Permalink
PEP8.
Browse files Browse the repository at this point in the history
  • Loading branch information
mbcosta committed Jul 11, 2018
1 parent 5f82406 commit d333c60
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
2 changes: 1 addition & 1 deletion l10n_br_account_product/models/account_payment.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Magno Costa <[email protected]>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html)

from openerp import models, api, fields
from openerp import models, fields


class PaymentMode(models.Model):
Expand Down
15 changes: 6 additions & 9 deletions l10n_br_account_product/sped/nfe/document.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,8 @@ def _receiver(self, invoice, company, nfe_environment):

if invoice.partner_id.is_company:
self.nfe.infNFe.dest.IE.valor = punctuation_rm(
invoice.partner_id.inscr_est)
invoice.partner_id.inscr_est
)

if invoice.partner_id.country_id.id == \
invoice.company_id.country_id.id:
Expand Down Expand Up @@ -355,16 +356,12 @@ def _details(self, invoice, invoice_line, index):
self.det.prod.cProd.valor = invoice_line.product_id.code or ''
self.det.prod.cEAN.valor = invoice_line.product_id.ean13 or ''
self.det.prod.cEANTrib.valor = invoice_line.product_id.ean13 or ''
self.det.prod.xProd.valor = (normalize(
'NFKD', unicode(
invoice_line.product_id.name[:120] or '')
).encode('ASCII', 'ignore'))
self.det.prod.xProd.valor = (normalize('NFKD', unicode(
invoice_line.product_id.name[:120] or '')).encode('ASCII', 'ignore'))
else:
self.det.prod.cProd.valor = invoice_line.code or ''
self.det.prod.xProd.valor = (normalize(
'NFKD', unicode(
invoice_line.name[:120] or '')
).encode('ASCII', 'ignore'))
self.det.prod.xProd.valor = (normalize('NFKD', unicode(
invoice_line.name[:120] or '')).encode('ASCII', 'ignore'))

self.det.prod.NCM.valor = punctuation_rm(
invoice_line.fiscal_classification_id.code or '')[:8]
Expand Down

0 comments on commit d333c60

Please sign in to comment.