|
@@ -22,8 +22,9 @@ class ResPartner(models.Model):
|
|
|
|
|
|
for invoice in customer.invoice_ids:
|
|
|
movelines = []
|
|
|
- for move in invoice.move_id:
|
|
|
+ currency_symbol = ""
|
|
|
|
|
|
+ for move in invoice.move_id:
|
|
|
for moveline in move.line_id:
|
|
|
if moveline.amount_residual > 0 and moveline.state != "draft":
|
|
|
movelines.append({
|
|
@@ -33,7 +34,10 @@ class ResPartner(models.Model):
|
|
|
'debit': moveline.debit,
|
|
|
'date_maturity': moveline.date_maturity
|
|
|
})
|
|
|
- # domain=['&', ('reconcile_id', '=', False), '&', ('account_id.active','=', True), '&', ('account_id.type', '=', 'receivable'), ('state', '!=', 'draft')])
|
|
|
+
|
|
|
+ for currency in invoice.currency_id:
|
|
|
+ currency_symbol=currency.symbol
|
|
|
+
|
|
|
if invoice.state == 'open':
|
|
|
invoices.append({
|
|
|
'id': invoice.id,
|
|
@@ -41,7 +45,8 @@ class ResPartner(models.Model):
|
|
|
'date_invoice': invoice.date_invoice,
|
|
|
'amount_total': invoice.amount_total,
|
|
|
'residual': invoice.residual,
|
|
|
- 'moveLines': movelines
|
|
|
+ 'moveLines': movelines,
|
|
|
+ 'currency_symbol' : currency_symbol
|
|
|
})
|
|
|
|
|
|
partners.append({
|