From 9c4649693a4fe09deef5339947fffa0f40e06bbb Mon Sep 17 00:00:00 2001 From: "Bharat (OpenERP)" Date: Mon, 19 Sep 2011 17:28:56 +0530 Subject: [PATCH] [REM] removed the unnecessary files of account_tax_code and removed its reference from __init__.py of report folder in account module bzr revid: bde@tinyerp.com-20110919115856-xv87ze79aav7ztnd --- addons/account/report/__init__.py | 1 - addons/account/report/account_tax_code.py | 63 --------- addons/account/report/account_tax_code.rml | 144 --------------------- 3 files changed, 208 deletions(-) delete mode 100644 addons/account/report/account_tax_code.py delete mode 100644 addons/account/report/account_tax_code.rml diff --git a/addons/account/report/__init__.py b/addons/account/report/__init__.py index 7c09027f3ca..4d69ee41f84 100644 --- a/addons/account/report/__init__.py +++ b/addons/account/report/__init__.py @@ -33,7 +33,6 @@ import account_print_overdue import account_aged_partner_balance #import tax_report import account_tax_report -import account_tax_code import account_balance_landscape import account_invoice_report import account_report diff --git a/addons/account/report/account_tax_code.py b/addons/account/report/account_tax_code.py deleted file mode 100644 index 56895987b45..00000000000 --- a/addons/account/report/account_tax_code.py +++ /dev/null @@ -1,63 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# Copyright (C) 2004-2010 Tiny SPRL (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## - -import time -from report import report_sxw - -def _get_country(record): - if record.partner_id \ - and record.partner_id.address \ - and record.partner_id.address[0].country_id: - return record.partner_id.address[0].country_id.code - else: - return '' - -def _record_to_report_line(record): - return {'date': record.date, - 'ref': record.ref, - 'acode': record.account_id.code, - 'name': record.name, - 'debit': record.debit, - 'credit': record.credit, - 'pname': record.partner_id and record.partner_id.name or '', - 'country': _get_country(record) - } - -class account_tax_code_report(report_sxw.rml_parse): - def __init__(self, cr, uid, name, context): - super(account_tax_code_report, self).__init__(cr, uid, name, context=context) - self.localcontext.update({ - 'time': time, - 'get_line':self.get_line, - }) - - def get_line(self, obj): - line_ids = self.pool.get('account.move.line').search(self.cr, self.uid, [('tax_code_id','=',obj.id)]) - if not line_ids: return [] - - return map(_record_to_report_line, - self.pool.get('account.move.line')\ - .browse(self.cr, self.uid, line_ids)) - -report_sxw.report_sxw('report.account.tax.code.entries', 'account.tax.code', - 'addons/account/report/account_tax_code.rml', parser=account_tax_code_report, header="internal") - -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/account/report/account_tax_code.rml b/addons/account/report/account_tax_code.rml deleted file mode 100644 index 7489ac72a39..00000000000 --- a/addons/account/report/account_tax_code.rml +++ /dev/null @@ -1,144 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [[ repeatIn(objects, 'o') ]] - - - - Accounting Entries-[[ company.currency_id.name ]] - - - - - - - - - - Date - - - Voucher No - - - A/c Code - - - Third Party (Country) - - - Entry Label - - - Debit - - - Credit - - - -
- [[ repeatIn(get_line(o),'line') ]] - - - - [[ not line and removeParentNode('blockTable') ]] [[ formatLang(line['date'],date=True) ]] - - - [[ line['ref'] ]] - - - [[ line['acode'] ]] - - - [[ line['pname'] ]] ([[ line['country'] ]] ) - - - [[ line['name'] ]] - - - [[ formatLang(line['debit']) ]] [[ company.currency_id.symbol]] - - - [[ formatLang(line['credit']) ]] [[ company.currency_id.symbol]] - - - - - - -
-
-
\ No newline at end of file