Date Description Ref Maturity date Due Paid Maturity Li. [[ repeatIn(objects,'o') ]] [[ setLang(o.lang) ]] [[ o.title.name or '' ]] [[ o.name ]] [[ display_address(o.partner_id) ]] VAT: [[ o.vat or removeParentNode('para') ]] Document: Customer account statement Date: [[ formatLang(time.strftime('%Y-%m-%d'),date=True) ]] Customer Ref: [[ o.ref or ' ']]
[[ not getLines(o) and removeParentNode('section')]]
[[repeatIn(message(o, company), 'message_line') ]] [[ message_line ]]
Date Description Ref Maturity date Due Paid Maturity Li.
[[repeatIn(getLines(o), 'line') ]] [[ formatLang(line['date'],date=True) ]] [[ line['name'] ]] [[ line['ref'] ]] [[ line['date_maturity'] and formatLang(line['date_maturity'],date=True) or '' ]] [[ (line['account_id']['type'] == 'receivable' and formatLang(line['debit']) or 0) or (line['account_id']['type'] == 'payable' and formatLang(line['credit'] * -1) or ' ') ]] [[ (line['account_id']['type'] == 'receivable' and formatLang(line['credit']) or 0) or (line['account_id']['type'] == 'payable' and formatLang(line['debit'] * -1) or 0) ]] [[ time.strftime('%Y-%m-%d') > formatLang((line['date_maturity'])) and formatLang(line['debit'] - line['credit'], currency_obj = company.currency_id) ]] [[ line['blocked'] and 'X' or '' ]]
Sub-Total : [[ formatLang((reduce(lambda x, y: x + ((y['account_id']['type'] == 'receivable' and y['debit'] or 0) or (y['account_id']['type'] == 'payable' and y['credit'] * -1 or 0)), getLines(o), 0))) ]] [[ formatLang((reduce(lambda x, y: x + ((y['account_id']['type'] == 'receivable' and y['credit'] or 0) or (y['account_id']['type'] == 'payable' and y['debit'] * -1 or 0)), getLines(o), 0))) ]] [[ formatLang((reduce(lambda x, y: x + (y['debit'] - y['credit']), filter(lambda x: x['date_maturity'] < time.strftime('%Y-%m-%d'), getLines(o)), 0)), currency_obj=company.currency_id) ]] Balance : [[ formatLang((reduce(lambda x, y: x +(y['debit'] - y['credit']), getLines(o), 0)), currency_obj = company.currency_id) ]] Total amount due: [[ formatLang((reduce(lambda x, y: x + (y['debit'] - y['credit']), getLines(o), 0)), currency_obj=company.currency_id) ]]
[[ getLines(o) and removeParentNode('section')]]There is nothing due with this customer