From 4ab597d6e798d4e975f3db70fed81e20e131a5ee Mon Sep 17 00:00:00 2001 From: "Apa (Open ERP)" Date: Tue, 10 Feb 2009 11:07:41 +0530 Subject: [PATCH] formated account followup report with new style(vir) bzr revid: apa@tinyerp.com-20090210053741-wh7hcpbh6lrfavgx --- addons/account_followup/report/rappel.rml | 300 +++++++++++++--------- 1 file changed, 184 insertions(+), 116 deletions(-) diff --git a/addons/account_followup/report/rappel.rml b/addons/account_followup/report/rappel.rml index 3f28abfd206..257365ce807 100644 --- a/addons/account_followup/report/rappel.rml +++ b/addons/account_followup/report/rappel.rml @@ -17,45 +17,46 @@ - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - @@ -63,160 +64,227 @@ + + + + + + + + + + + + + + + + + + + + + + + + - [[ repeatIn(ids_to_objects(data['form']['partner_ids']),'o') ]] [[ setLang(o.lang) ]] + [[ repeatIn(ids_to_objects(data['form']['partner_ids']),'o') ]] + [[ setLang(o.lang) ]] - - - + [[ repeatIn(adr_get(o,'invoice'),'a' )]] - [[ o.name ]] - [[ repeatIn(adr_get(o,'invoice'),'a' )]] - [[ a['name'] ]] - [[ a['street'] ]] - [[ a['zip'] ]] - [[ a['city'] ]] - [[( a['country_id'] and a['country_id'][1]) or '']] - + [[ o.name ]] + [[ a['name'] ]] + [[ a['street'] ]] + [[ a['zip'] ]] + [[ a['city'] ]] + [[( a['country_id'] and a['country_id'][1]) or '']] + - VAT: [[ o.vat or removeParentNode('para') ]] + VAT: [[ o.vat or removeParentNode('para') ]] - + - Document: Customer account statement - - Date: - [[ time.strftime('%d/%m/%Y') ]] - - Customer Ref: [[ o.id ]] - + Document : Customer account statement + Date : [[ formatLang(time.strftime('%Y-%m-%d'),date = True) ]] + Customer Ref : [[ o.id ]] + - [[ format(get_text(o,data['form']['followup_id'])) ]] - + [[ format(get_text(o,data['form']['followup_id'])) ]] + - + - Date + Invoice Date - Description + Description - Ref + Ref - Maturity date + Maturity Date - Due + Amount In Currency - Paid + Due - Maturity + Paid - Amount + Maturity - Li. - - - - - - [[repeatIn(getLines(o), 'line') ]] - [[ line['date'] ]] - - - - [[ line['name'] ]] - - - [[ line['ref'] ]] - - - [[ line['date_maturity'] ]] - - - [[ line['debit'] and '%.2f' % line['debit'] or '' ]] [[ company.currency_id.name]] - - - [[ line['credit'] and '%.2f' % line['credit'] or '0.00' ]] [[ company.currency_id.name]] - - - [[ (line['date_maturity'] < time.strftime('%Y-%m-%d')) and (line['debit'] - line['credit']) or '' ]] [[ company.currency_id.name]] - - - [[ '%.2f' % line['amount_currency'] ]] [[ line['currency_id'] and line['currency_id'][1] or '' ]] - - - [[ line['blocked'] and 'X' or '' ]] + Li. - +
+ [[repeatIn(getLines(o), 'line') ]] + + + + [[ formatLang(line['date'],date = True) ]] + + + [[ line['name'] ]] + + + [[ line['ref'] ]] + + + [[ line['date_maturity'] ]] + + + [[ formatLang(line['amount_currency'] )]] [[ line['currency_id'] and line['currency_id'][1] or '' ]] + + + [[ formatLang(line['debit']) ]] [[ company.currency_id.name]] + + + [[ formatLang(line['credit']) ]] [[ company.currency_id.name]] + + + [[ (line['date_maturity'] < time.strftime('%Y-%m-%d')) and (line['debit'] -line['credit']) or '0.00' ]] [[ company.currency_id.name]] + + + [[ line['blocked'] and 'X' or '' ]] + + + +
+ - Sub-Total: + + + - [[ '%.2f' % (reduce(lambda x,y: x+y['debit'], getLines(o), 0)) ]] [[ company.currency_id.name]] + + + - [[ '%.2f' % (reduce(lambda x,y: x+y['credit'], getLines(o), 0)) ]] [[ company.currency_id.name]] + + + - [[ reduce(lambda x,y: x+(y['debit'] - y['credit']), filter(lambda x: x['date_maturity'] < time.strftime('%Y-%m-%d'), getLines(o)), 0) ]] [[ company.currency_id.name]] + + + - + + + + + + Sub-Total: + + + [[formatLang(reduce(lambda x,y: x+y['debit'], getLines(o), 0.00)) ]] [[ company.currency_id.name]] + + + [[formatLang(reduce(lambda x,y: x+y['credit'], getLines(o), 0.00)) ]] [[ company.currency_id.name]] + + + [[ reduce(lambda x,y: x+(y['debit'] - y['credit']), filter(lambda x: x['date_maturity'] < time.strftime('%Y-%m-%d'), getLines(o)), 0) ]] [[ company.currency_id.name]] + + + - Balance: - - - [[ '%.2f' % (reduce(lambda x,y: x+(y['debit'] - y['credit']), getLines(o), 0)) ]] [[ company.currency_id.name]] - - - + - + - + + + + + + + + + + + + + + + + Balance: + + + [[ '%.2f' % (reduce(lambda x,y: x+(y['debit'] - y['credit']), getLines(o), 0.00)) ]] [[ company.currency_id.name]] + + + + + + + + + + + + + - - - - +
-