diff --git a/addons/account/__openerp__.py b/addons/account/__openerp__.py index f06123487e2..3923add4fe0 100644 --- a/addons/account/__openerp__.py +++ b/addons/account/__openerp__.py @@ -45,7 +45,6 @@ module named account_voucher. 'init_xml': [], "depends" : ["product", "analytic", "process","board"], 'update_xml': [ - #'test/test_parent_structure.yml', 'security/account_security.xml', 'security/ir.model.access.csv', 'account_menuitem.xml', @@ -80,7 +79,6 @@ module named account_voucher. 'wizard/account_invoice_state_view.xml', 'wizard/account_report_partner_balance_view.xml', 'wizard/account_report_account_balance_view.xml', -# 'wizard/account_move_line_select_view.xml', 'wizard/account_report_aged_partner_balance_view.xml', 'wizard/account_compare_account_balance_report_view.xml', 'wizard/account_report_partner_ledger_view.xml', @@ -120,7 +118,6 @@ module named account_voucher. "wizard/account_report_balance_sheet_view.xml" ], 'demo_xml': [ - #'demo/price_accuracy00.yml', 'account_demo.xml', 'project/project_demo.xml', 'project/analytic_account_demo.xml', @@ -135,7 +132,6 @@ module named account_voucher. 'test/chart_of_account.yml', 'test/account_period_close.yml', 'test/account_fiscalyear_close_state.yml', - #'test/account_invoice_state.yml', 'test/account_use_model.yml', 'test/account_validate_account_move.yml', 'test/account_fiscalyear_close.yml', diff --git a/addons/account/account.py b/addons/account/account.py index d0e4e66cd60..1f54a9b2c52 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -693,14 +693,6 @@ class account_journal(osv.osv): 'sequence_id':seq_id }) -# if journal.type in journal_type and not journal.invoice_sequence_id: -# res_ids = date_pool.search(cr, uid, [('model','=','ir.sequence'), ('name','=',journal_seq.get(journal.type, 'sale'))]) -# inv_seq_id = date_pool.browse(cr, uid, res_ids[0]).res_id -# inv_seq_id -# res.update({ -# 'invoice_sequence_id':inv_seq_id -# }) - result = self.write(cr, uid, [journal.id], res) return result @@ -708,16 +700,6 @@ class account_journal(osv.osv): def create(self, cr, uid, vals, context={}): journal_id = super(account_journal, self).create(cr, uid, vals, context) self.create_sequence(cr, uid, [journal_id], context) - -# journal_name = self.browse(cr, uid, [journal_id])[0].code -# periods = self.pool.get('account.period') -# ids = periods.search(cr, uid, [('date_stop','>=',time.strftime('%Y-%m-%d'))]) -# for period in periods.browse(cr, uid, ids): -# self.pool.get('account.journal.period').create(cr, uid, { -# 'name': (journal_name or '')+':'+(period.code or ''), -# 'journal_id': journal_id, -# 'period_id': period.id -# }) return journal_id def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=100): @@ -731,7 +713,6 @@ class account_journal(osv.osv): if name: ids = self.search(cr, user, [('code', 'ilike', name)]+ args, limit=limit, context=context) if not ids: -# ids = self.search(cr, user, [('name', operator, name)]+ args, limit=limit, context=context) ids = self.search(cr, user, [('name', 'ilike', name)]+ args, limit=limit, context=context)#fix it ilike should be replace with operator return self.name_get(cr, user, ids, context=context) @@ -1419,8 +1400,6 @@ class account_move(osv.osv): self.pool.get('account.move.line').write(cr, uid, line_ids, { 'journal_id': move.journal_id.id, 'period_id': move.period_id.id, - #'tax_code_id': False, - #'tax_amount': False, 'state': 'draft' }, context, check=False) # Create analytic lines for the valid moves @@ -1903,8 +1882,6 @@ class account_tax(osv.osv): amount = localdict['result'] elif tax.type=='balance': amount = cur_price_unit - reduce(lambda x,y: y.get('amount',0.0)+x, res, 0.0) -# data['balance'] = cur_price_unit - if tax.include_base_amount: cur_price_unit -= amount @@ -2257,12 +2234,8 @@ class account_add_tmpl_wizard(osv.osv_memory): data= self.read(cr, uid, ids) company_id = acc_obj.read(cr, uid, [data[0]['cparent_id']], ['company_id'])[0]['company_id'][0] account_template = tmpl_obj.browse(cr, uid, context['tmpl_ids']) - #tax_ids = [] - #for tax in account_template.tax_ids: - # tax_ids.append(tax_template_ref[tax.id]) vals={ 'name': account_template.name, - #'sign': account_template.sign, 'currency_id': account_template.currency_id and account_template.currency_id.id or False, 'code': account_template.code, 'type': account_template.type, @@ -2271,7 +2244,6 @@ class account_add_tmpl_wizard(osv.osv_memory): 'shortcut': account_template.shortcut, 'note': account_template.note, 'parent_id': data[0]['cparent_id'], - # 'tax_ids': [(6,0,tax_ids)], todo!! 'company_id': company_id, } new_account = acc_obj.create(cr, uid, vals) @@ -2588,7 +2560,6 @@ class wizard_multi_charts_accounts(osv.osv_memory): code_acc=str(code_acc) + (str('0'*(dig-code_main))) vals={ 'name': (obj_acc_root.id == account_template.id) and obj_multi.company_id.name or account_template.name, - #'sign': account_template.sign, 'currency_id': account_template.currency_id and account_template.currency_id.id or False, 'code': code_acc, 'type': account_template.type, diff --git a/addons/account/account_analytic_line.py b/addons/account/account_analytic_line.py index 1792525a7f6..36fc350dfb8 100644 --- a/addons/account/account_analytic_line.py +++ b/addons/account/account_analytic_line.py @@ -42,7 +42,7 @@ class account_analytic_line(osv.osv): _defaults = { 'date': lambda *a: time.strftime('%Y-%m-%d'), 'company_id': lambda self,cr,uid,c: self.pool.get('res.company')._company_default_get(cr, uid, 'account.analytic.line', context=c), - } + } _order = 'date' def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False): @@ -65,7 +65,6 @@ class account_analytic_line(osv.osv): return False return True _constraints = [ -# (_check_company, 'You can not create analytic line that is not in the same company than the account line', ['account_id']) ] # Compute the cost based on the price type define into company diff --git a/addons/account/account_assert_test.xml b/addons/account/account_assert_test.xml index 585c6bda124..ba5f9840ccc 100644 --- a/addons/account/account_assert_test.xml +++ b/addons/account/account_assert_test.xml @@ -4,25 +4,5 @@ - - - diff --git a/addons/account/account_bank_statement.py b/addons/account/account_bank_statement.py index 6ddea9645b4..e8cafd2443b 100644 --- a/addons/account/account_bank_statement.py +++ b/addons/account/account_bank_statement.py @@ -367,8 +367,6 @@ class account_bank_statement(osv.osv): account_move_line_obj.reconcile(cr, uid, torec, 'statement', writeoff_acc_id=writeoff_acc_id, writeoff_period_id=st.period_id.id, writeoff_journal_id=st.journal_id.id, context=context) else: account_move_line_obj.reconcile_partial(cr, uid, torec, 'statement', context) - #except: - # raise osv.except_osv(_('Error !'), _('Unable to reconcile entry "%s": %.2f') % (move.name, move.amount)) if st.journal_id.entry_posted: account_move_obj.write(cr, uid, [move_id], {'state': 'posted'}) diff --git a/addons/account/account_cash_statement.py b/addons/account/account_cash_statement.py index f08f9de2f8f..8bf75a8dd03 100644 --- a/addons/account/account_cash_statement.py +++ b/addons/account/account_cash_statement.py @@ -118,19 +118,6 @@ class account_cash_statement(osv.osv): res2[statement.id]=encoding_total return res2 -# def _default_journal_id(self, cr, uid, context={}): - -# """ To get default journal for the object" -# @param name: Names of fields. -# @return: journal -# """ -# company_id = self.pool.get('res.users').browse(cr, uid, uid).company_id.id -# journal = self.pool.get('account.journal').search(cr, uid, [('type', '=', 'cash'), ('company_id', '=', company_id)]) -# if journal: -# return journal[0] -# else: -# return False - def _end_balance(self, cursor, user, ids, name, attr, context=None): res_currency_obj = self.pool.get('res.currency') res_users_obj = self.pool.get('res.users') @@ -374,10 +361,6 @@ class account_cash_statement(osv.osv): if not self._equal_balance(cr, uid, ids, st, context): raise osv.except_osv(_('Error !'), _('CashBox Balance is not matching with Calculated Balance !')) -# if not (abs((st.balance_end or 0.0) - st.balance_end_real) < 0.0001): -# raise osv.except_osv(_('Error !'), -# _('The statement balance is incorrect !\n') + -# _('The expected balance (%.2f) is different than the computed one. (%.2f)') % (st.balance_end_real, st.balance_end)) if (not st.journal_id.default_credit_account_id) \ or (not st.journal_id.default_debit_account_id): raise osv.except_osv(_('Configuration Error !'), diff --git a/addons/account/account_invoice_view.xml b/addons/account/account_invoice_view.xml index 6effce8f488..80c245638f7 100644 --- a/addons/account/account_invoice_view.xml +++ b/addons/account/account_invoice_view.xml @@ -421,7 +421,6 @@ - Customer Invoices diff --git a/addons/account/account_invoice_workflow.xml b/addons/account/account_invoice_workflow.xml index ba8d1ba2bc8..c3749eb8cf0 100644 --- a/addons/account/account_invoice_workflow.xml +++ b/addons/account/account_invoice_workflow.xml @@ -12,19 +12,6 @@ True draft - - - - - - - - - - @@ -65,35 +52,11 @@ write({'state':'cancel'}) function - - - - - - - invoice_open - - - - - - - - - - - - @@ -106,11 +69,6 @@ write({'state':'cancel'}) invoice_cancel - - - - - @@ -126,7 +84,7 @@ write({'state':'cancel'}) invoice_cancel - + @@ -134,7 +92,7 @@ write({'state':'cancel'}) move_line_id_payment_get() test_paid() - + diff --git a/addons/account/account_menuitem.xml b/addons/account/account_menuitem.xml index 74c8234860d..3cb21315350 100644 --- a/addons/account/account_menuitem.xml +++ b/addons/account/account_menuitem.xml @@ -6,13 +6,10 @@ - - - @@ -25,23 +22,12 @@ - - - - - - - - - - - diff --git a/addons/account/account_move_line.py b/addons/account/account_move_line.py index 94dd4e8eb86..4e6c2cb5d8d 100644 --- a/addons/account/account_move_line.py +++ b/addons/account/account_move_line.py @@ -572,7 +572,7 @@ class account_move_line(osv.osv): if journal: jt = self.pool.get('account.journal').browse(cr, uid, journal).type #FIXME: Bank and cash journal are such a journal we can not assume a account based on this 2 journals - # Bank and cash journal can have a payment or receipt transection, and in both type partner account + # Bank and cash journal can have a payment or receipt transaction, and in both type partner account # will not be same id payment then payable, and if receipt then receivable #if jt in ('sale', 'purchase_refund', 'bank', 'cash'): if jt in ('sale', 'purchase_refund'): @@ -1155,11 +1155,6 @@ class account_move_line(osv.osv): 'journal_id': journal.analytic_journal_id.id, 'ref': vals.get('ref', False), })] - #else: - # raise osv.except_osv(_('No analytic journal !'), _('Please set an analytic journal on this financial journal !')) - - #if not 'currency_id' in vals: - # vals['currency_id'] = account.company_id.currency_id.id result = super(osv.osv, self).create(cr, uid, vals, context) # CREATE Taxes @@ -1228,11 +1223,6 @@ class account_move_line(osv.osv): self.create(cr, uid, data, context) del vals['account_tax_id'] - # No needed, related to the job - #if not is_new_move and 'date' in vals: - # if context and ('__last_update' in context): - # del context['__last_update'] - # self.pool.get('account.move').write(cr, uid, [move_id], {'date':vals['date']}, context=context) if check and ((not context.get('no_store_function')) or journal.entry_posted): tmp = self.pool.get('account.move').validate(cr, uid, [vals['move_id']], context) if journal.entry_posted and tmp: diff --git a/addons/account/account_report.xml b/addons/account/account_report.xml index 8e26ee8553b..be0569fa65f 100644 --- a/addons/account/account_report.xml +++ b/addons/account/account_report.xml @@ -47,20 +47,6 @@ name="Taxes" parent="account.menu_finance_generic_reporting" sequence="3"/> - - - - - diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index bb0e96a8380..a8f0649a99e 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -160,7 +160,6 @@ - @@ -256,7 +255,6 @@ [('parent_id','=',False)] - - - - - - - account.bank.statement.reconcile.form account.bank.statement.reconcile @@ -871,7 +862,6 @@ id="menu_action_tax_code_tree" parent="menu_finance_charts" sequence="12"/> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Entry Lines ir.actions.act_window @@ -1434,26 +1371,8 @@ form - - - - - - - - - - - - - - - - account.bank.statement.reconcile.form @@ -1516,20 +1435,6 @@ form,tree - - - - - - - - - - tree You can look up individual account entries by searching for useful information. To search for account entries, open a journal, then select a record line. - - + # Account Models + --> account.model.line.tree @@ -1729,26 +1632,7 @@ - - - - - - - - - - - - - - - - - - - - + Payment Terms account.payment.term @@ -1758,8 +1642,8 @@ + # Account Subscriptions + --> account.subscription.line.form @@ -1813,7 +1697,6 @@ - @@ -1883,15 +1766,6 @@ [('account_id','child_of', [active_id]),('state','<>','draft')] {'account_id':active_id} - - - - - - - - - account.move.line.tax.tree diff --git a/addons/account/account_wizard.xml b/addons/account/account_wizard.xml index d7a879cdf20..639dc2dc111 100644 --- a/addons/account/account_wizard.xml +++ b/addons/account/account_wizard.xml @@ -1,100 +1,7 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/addons/account/board_account_demo.xml b/addons/account/board_account_demo.xml index cfcebdbcdf1..93bfed6d56d 100644 --- a/addons/account/board_account_demo.xml +++ b/addons/account/board_account_demo.xml @@ -2,16 +2,9 @@ - diff --git a/addons/account/company_view.xml b/addons/account/company_view.xml index a3a1ec0080a..692c7960bbf 100644 --- a/addons/account/company_view.xml +++ b/addons/account/company_view.xml @@ -7,12 +7,12 @@ res.company form - - - - - - + + + + + + diff --git a/addons/account/configurable_account_chart.xml b/addons/account/configurable_account_chart.xml index bfef98145a6..cd0305ec9b9 100644 --- a/addons/account/configurable_account_chart.xml +++ b/addons/account/configurable_account_chart.xml @@ -175,10 +175,6 @@ - - 1103 Output VAT @@ -195,14 +191,6 @@ - - - - - - - - 111 Current Liabilities @@ -220,10 +208,6 @@ - - 1112 Input VAT @@ -268,10 +252,6 @@ - - 21 Cost of Sales @@ -304,12 +284,8 @@ - - - + diff --git a/addons/account/demo/account_minimal.xml b/addons/account/demo/account_minimal.xml index cfcd6d0033d..2e56faa2733 100644 --- a/addons/account/demo/account_minimal.xml +++ b/addons/account/demo/account_minimal.xml @@ -411,18 +411,6 @@ Product income and expense accounts, default parameters --> - - - - - - - - - - - - property_account_expense_categ diff --git a/addons/account/installer.py b/addons/account/installer.py index 4843f54187c..6671241a4d4 100644 --- a/addons/account/installer.py +++ b/addons/account/installer.py @@ -71,7 +71,6 @@ class account_installer(osv.osv_memory): 'period':lambda *a:'month', 'sale_tax':lambda *a:0.0, 'purchase_tax':lambda *a:0.0, - #'charts':'configurable', 'bank_accounts_id':_get_default_accounts } diff --git a/addons/account/invoice.py b/addons/account/invoice.py index cff1ce60141..c2fbe5f9293 100644 --- a/addons/account/invoice.py +++ b/addons/account/invoice.py @@ -319,7 +319,6 @@ class account_invoice(osv.osv): } _defaults = { 'type': _get_type, - #'date_invoice': lambda *a: time.strftime('%Y-%m-%d'), 'state': 'draft', 'journal_id': _get_journal, 'currency_id': _get_currency, @@ -372,9 +371,6 @@ class account_invoice(osv.osv): osv.osv.unlink(self, cr, uid, unlink_ids, context=context) return True -# def get_invoice_address(self, cr, uid, ids): -# res = self.pool.get('res.partner').address_get(cr, uid, [part], ['invoice']) -# return [{}] def onchange_partner_id(self, cr, uid, ids, type, partner_id,\ date_invoice=False, payment_term=False, partner_bank_id=False, company_id=False): invoice_addr_id = False @@ -636,7 +632,6 @@ class account_invoice(osv.osv): ait_obj.create(cr, uid, taxe) # Update the stored value (fields.function), so we write to trigger recompute self.pool.get('account.invoice').write(cr, uid, ids, {'invoice_line':[]}, context=context) -# self.pool.get('account.invoice').write(cr, uid, ids, {}, context=context) return True def button_compute(self, cr, uid, ids, context=None, set_total=False): @@ -879,7 +874,7 @@ class account_invoice(osv.osv): line = self.group_lines(cr, uid, iml, line, inv) - journal_id = inv.journal_id.id #self._get_journal(cr, uid, {'type': inv['type']}) + journal_id = inv.journal_id.id journal = self.pool.get('account.journal').browse(cr, uid, journal_id) if journal.centralisation: raise osv.except_osv(_('UserError'), @@ -1321,9 +1316,6 @@ class account_invoice_line(osv.osv): else: app_acc_in = in_acc_cate app_acc_exp = ex_acc_cate -# else: -# app_acc_in = self.pool.get('account.account').browse(cr,uid,in_pro_id)[0] -# app_acc_exp = self.pool.get('account.account').browse(cr,uid,exp_pro_id)[0] if app_acc_in.company_id.id != company_id and app_acc_exp.company_id.id != company_id: in_res_id = account_obj.search(cr, uid, [('name','=',app_acc_in.name),('company_id','=',company_id)]) exp_res_id = account_obj.search(cr, uid, [('name','=',app_acc_exp.name),('company_id','=',company_id)]) diff --git a/addons/account/partner_view.xml b/addons/account/partner_view.xml index 609b8f0da5a..f3a8cca8ada 100644 --- a/addons/account/partner_view.xml +++ b/addons/account/partner_view.xml @@ -63,7 +63,7 @@ + --> res.partner.property.form.inherit diff --git a/addons/account/process/customer_invoice_process.xml b/addons/account/process/customer_invoice_process.xml index 172de7b7b1c..1f04c8e023b 100644 --- a/addons/account/process/customer_invoice_process.xml +++ b/addons/account/process/customer_invoice_process.xml @@ -1,21 +1,21 @@ - - - + - - - + @@ -26,7 +26,7 @@ - + @@ -37,7 +37,7 @@ - + @@ -48,7 +48,7 @@ - + @@ -58,7 +58,7 @@ - + @@ -70,7 +70,7 @@ - + @@ -81,7 +81,7 @@ - + @@ -92,7 +92,7 @@ - + @@ -103,7 +103,7 @@ - + @@ -115,20 +115,16 @@ - - - + - - - - - + @@ -137,7 +133,7 @@ - + @@ -146,7 +142,7 @@ - + @@ -156,7 +152,7 @@ - + @@ -165,7 +161,7 @@ - + @@ -174,7 +170,7 @@ - + @@ -183,7 +179,7 @@ - + @@ -192,7 +188,7 @@ - + @@ -201,17 +197,17 @@ - - - + - + diff --git a/addons/account/project/project_report.xml b/addons/account/project/project_report.xml index ae6aedeaab1..0bc8077761e 100644 --- a/addons/account/project/project_report.xml +++ b/addons/account/project/project_report.xml @@ -3,32 +3,15 @@ - - - - - - - - - - - - - - - - - diff --git a/addons/account/project/project_view.xml b/addons/account/project/project_view.xml index 4bdab312ad2..2879cdede2a 100644 --- a/addons/account/project/project_view.xml +++ b/addons/account/project/project_view.xml @@ -60,11 +60,6 @@ - - - - - @@ -112,7 +107,6 @@ {"search_default_user_id":uid} - @@ -135,17 +129,8 @@ Analytic Charts of Accounts allows you to access to reports by analytic accounts (or cost accounts) . From this menu you can access to analytic balance, a report that relates the analytic accounts to the general accounts. It is useful for analyzing the profitability of projects, giving you the profitability of a project for the different operations that you used to carry out the project. - - - - - - - - account.analytic.line.form @@ -230,14 +215,8 @@ {"search_default_user_id":uid} - - - - - - - + Analytic Entries @@ -355,30 +334,6 @@ tree,form - - - - - - - - - - - - # # Reporting @@ -392,15 +347,6 @@ - - - - - - - - - # # Statistics # @@ -476,7 +422,6 @@ tree,graph - diff --git a/addons/account/project/wizard/account_analytic_balance_report.py b/addons/account/project/wizard/account_analytic_balance_report.py index b751808ffb9..2a0a8bba7a8 100644 --- a/addons/account/project/wizard/account_analytic_balance_report.py +++ b/addons/account/project/wizard/account_analytic_balance_report.py @@ -30,12 +30,12 @@ class account_analytic_balance(osv.osv_memory): 'date1': fields.date('Start of period', required=True), 'date2': fields.date('End of period', required=True), 'empty_acc': fields.boolean('Empty Accounts ? ', help='Check if you want to display Accounts with 0 balance too.'), - } + } _defaults = { 'date1':time.strftime('%Y-01-01'), 'date2':time.strftime('%Y-%m-%d') - } + } def check_report(self, cr, uid, ids, context=None): datas = {} diff --git a/addons/account/project/wizard/account_analytic_chart.py b/addons/account/project/wizard/account_analytic_chart.py index dc55d6c43e7..89155810fc0 100644 --- a/addons/account/project/wizard/account_analytic_chart.py +++ b/addons/account/project/wizard/account_analytic_chart.py @@ -27,7 +27,7 @@ class account_analytic_chart(osv.osv_memory): _columns = { 'from_date': fields.date('From'), 'to_date': fields.date('To'), - } + } def analytic_account_chart_open_window(self, cr, uid, ids, context=None): mod_obj = self.pool.get('ir.model.data') diff --git a/addons/account/project/wizard/account_analytic_check.py b/addons/account/project/wizard/account_analytic_check.py index 48c89df8fc4..53327963151 100644 --- a/addons/account/project/wizard/account_analytic_check.py +++ b/addons/account/project/wizard/account_analytic_check.py @@ -29,12 +29,12 @@ class account_analytic_check(osv.osv_memory): _columns = { 'date1': fields.date('Start of period', required=True), 'date2': fields.date('End of period', required=True), - } + } _defaults = { 'date1':time.strftime('%Y-01-01'), 'date2':time.strftime('%Y-%m-%d') - } + } def check_report(self, cr, uid, ids, context=None): datas = {} diff --git a/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report.py b/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report.py index 6074fee3f08..ad1ea42c29f 100644 --- a/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report.py +++ b/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report.py @@ -30,12 +30,12 @@ class account_analytic_cost_ledger_journal_report(osv.osv_memory): 'date1': fields.date('Start of period', required=True), 'date2': fields.date('End of period', required=True), 'journal': fields.many2many('account.analytic.journal', 'ledger_journal_rel', 'ledger_id', 'Journal_id', 'Journals'), - } + } _defaults = { 'date1':time.strftime('%Y-01-01'), 'date2':time.strftime('%Y-%m-%d') - } + } def check_report(self, cr, uid, ids, context=None): datas = {} diff --git a/addons/account/project/wizard/account_analytic_cost_ledger_report.py b/addons/account/project/wizard/account_analytic_cost_ledger_report.py index 96b480b4fb5..d228499e5bd 100644 --- a/addons/account/project/wizard/account_analytic_cost_ledger_report.py +++ b/addons/account/project/wizard/account_analytic_cost_ledger_report.py @@ -29,12 +29,12 @@ class account_analytic_cost_ledger(osv.osv_memory): _columns = { 'date1': fields.date('Start of period', required=True), 'date2': fields.date('End of period', required=True), - } + } _defaults = { 'date1':time.strftime('%Y-01-01'), 'date2':time.strftime('%Y-%m-%d') - } + } def check_report(self, cr, uid, ids, context=None): datas = {} diff --git a/addons/account/project/wizard/account_analytic_inverted_balance_report.py b/addons/account/project/wizard/account_analytic_inverted_balance_report.py index 52f7da936fe..0fac1ba8dec 100644 --- a/addons/account/project/wizard/account_analytic_inverted_balance_report.py +++ b/addons/account/project/wizard/account_analytic_inverted_balance_report.py @@ -29,12 +29,12 @@ class account_analytic_inverted_balance(osv.osv_memory): _columns = { 'date1': fields.date('Start of period', required=True), 'date2': fields.date('End of period', required=True), - } + } _defaults = { 'date1':time.strftime('%Y-01-01'), 'date2':time.strftime('%Y-%m-%d') - } + } def check_report(self, cr, uid, ids, context=None): datas = {} diff --git a/addons/account/project/wizard/account_analytic_journal_report.py b/addons/account/project/wizard/account_analytic_journal_report.py index aef6a85149d..06bec940f89 100644 --- a/addons/account/project/wizard/account_analytic_journal_report.py +++ b/addons/account/project/wizard/account_analytic_journal_report.py @@ -29,12 +29,12 @@ class account_analytic_Journal_report(osv.osv_memory): _columns = { 'date1': fields.date('Start of period', required=True), 'date2': fields.date('End of period', required=True), - } + } _defaults = { 'date1':time.strftime('%Y-01-01'), 'date2':time.strftime('%Y-%m-%d') - } + } def check_report(self, cr, uid, ids, context=None): datas = {} diff --git a/addons/account/project/wizard/project_account_analytic_line.py b/addons/account/project/wizard/project_account_analytic_line.py index dbe3df3c819..5437abe5be7 100644 --- a/addons/account/project/wizard/project_account_analytic_line.py +++ b/addons/account/project/wizard/project_account_analytic_line.py @@ -27,7 +27,7 @@ class project_account_analytic_line(osv.osv_memory): _columns = { 'from_date': fields.date('From'), 'to_date': fields.date('To'), - } + } def action_open_window(self, cr, uid, ids, context={}): mod_obj =self.pool.get('ir.model.data') diff --git a/addons/account/project/wizard/project_account_analytic_line_view.xml b/addons/account/project/wizard/project_account_analytic_line_view.xml index d564ffb5c81..926c783b444 100644 --- a/addons/account/project/wizard/project_account_analytic_line_view.xml +++ b/addons/account/project/wizard/project_account_analytic_line_view.xml @@ -28,8 +28,8 @@ project.account.analytic.line form tree,form - - new + + new diff --git a/addons/account/report/account_aged_partner_balance.py b/addons/account/report/account_aged_partner_balance.py index a70d79cdd40..8e07f3ad56c 100644 --- a/addons/account/report/account_aged_partner_balance.py +++ b/addons/account/report/account_aged_partner_balance.py @@ -181,10 +181,6 @@ class aged_trial_report(rml_parse.rml_parse, common_report_header): ## Add for total self.total_account[(i+1)] = self.total_account[(i+1)] + (total and total[0] or 0.0) values['name'] = partner['name'] - #t = 0.0 - #for i in range(5)+['direction']: - # t+= float(values.get(str(i), 0.0) or 0.0) - #values['total'] = t if values['total']: res.append(values) @@ -217,7 +213,7 @@ class aged_trial_report(rml_parse.rml_parse, common_report_header): return 'Payable Accounts' elif data['form']['result_selection'] == 'customer_supplier': return 'Receivable and Payable Accounts' - return '' + return '' report_sxw.report_sxw('report.account.aged_trial_balance', 'res.partner', 'addons/account/report/account_aged_partner_balance.rml',parser=aged_trial_report, header=False) diff --git a/addons/account/report/account_balance.py b/addons/account/report/account_balance.py index 076369f7e10..79e2334b7dc 100644 --- a/addons/account/report/account_balance.py +++ b/addons/account/report/account_balance.py @@ -86,10 +86,6 @@ class account_balance(report_sxw.rml_parse, common_report_header): elif form['filter'] == 'filter_date': ctx['date_from'] = form['date_from'] ctx['date_to'] = form['date_to'] -# accounts = obj_account.browse(self.cr, self.uid, ids, ctx) -# def cmp_code(x, y): -# return cmp(x.code, y.code) -# accounts.sort(cmp_code) child_ids = obj_account._get_children_and_consol(self.cr, self.uid, ids, ctx) if child_ids: @@ -108,28 +104,11 @@ class account_balance(report_sxw.rml_parse, common_report_header): 'debit': account['debit'], 'credit': account['credit'], 'balance': account['balance'], - # 'leef': not bool(account['child_id']), 'parent_id':account['parent_id'], 'bal_type':'', } self.sum_debit += account['debit'] self.sum_credit += account['credit'] -# if account.child_id: -# def _check_rec(account): -# if not account.child_id: -# return bool(account.credit or account.debit) -# for c in account.child_id: -# if not _check_rec(c) or _check_rec(c): -# return True -# return False -# if not _check_rec(account) : -# continue -# if account['parent_id']: -# acc = obj_account.read(self.cr, self.uid, [ account['parent_id'][0] ] ,['name'], ctx) -# for r in result_acc: -# if r['id'] == account['parent_id'][0]: -# res['level'] = r['level'] + 1 -# break if form['display_account'] == 'bal_movement': if res['credit'] > 0 or res['debit'] > 0 or res['balance'] > 0 : result_acc.append(res) @@ -138,16 +117,6 @@ class account_balance(report_sxw.rml_parse, common_report_header): result_acc.append(res) else: result_acc.append(res) -# if account.child_id: -# acc_id = [acc.id for acc in account.child_id] -# lst_string = '' -# lst_string = '\'' + '\',\''.join(map(str,acc_id)) + '\'' -# self.cr.execute("select code,id from account_account where id IN (%s)"%(lst_string)) -# a_id = self.cr.fetchall() -# a_id.sort() -# ids2 = [x[1] for x in a_id] -# -# result_acc += self.lines(form, ids2, done, level+1) return result_acc report_sxw.report_sxw('report.account.account.balance', 'account.account', 'addons/account/report/account_balance.rml', parser=account_balance, header="internal") diff --git a/addons/account/report/account_balance_landscape.py b/addons/account/report/account_balance_landscape.py index 02d69ba8b19..e8b8502e331 100644 --- a/addons/account/report/account_balance_landscape.py +++ b/addons/account/report/account_balance_landscape.py @@ -24,8 +24,6 @@ import locale from report import report_sxw import rml_parse -#from addons.account.wizard import wizard_account_balance_report - parents = { 'tr':1, 'li':1, @@ -59,267 +57,6 @@ class account_balance_landscape(rml_parse.rml_parse): }) self.context = context -# def repeatIn(self, lst, name, nodes_parent=False,td=False,width=[],value=[],type=[]): -# self._node.data = '' -# node = self._find_parent(self._node, nodes_parent or parents) -# ns = node.nextSibling -##start -# if value==['Cash','%']: -# if show==1: -# if perc==1: -# if pattern=='none': -# value=['','Cash','%'] -# type=['lable','lable','lable'] -# width=[130,65,65] -# else: -# value=[' ','','Cash','%'] -# type=['string','lable','lable','lable'] -# width=[65,130,65,65] -# else: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[195] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,195] -# else: -# if perc==1: -# if pattern=='none': -# value=['Cash','%'] -# type=['lable','lable'] -# width=[65,65] -# else: -# value=[' ','Cash','%'] -# type=['string','lable','lable'] -# width=[65,65,65] -# else: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[65] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,65] -# -# -# if value==['year']: -# if show==1: -# if perc==1: -# if pattern=='none': -# width=[260] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,260] -# else: -# if pattern=='none': -# width=[195] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,195] -# else: -# if perc==1: -# if pattern=='none': -# width=[130] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,130] -# -# else: -# if pattern=='none': -# width=[65] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,65] -# -# if value==['Debit','Credit','Balance']: -# if show==1: -# if perc==1: -# if pattern=='none': -# width=[65,65,130] -# else: -# value=[' ','Debit','Credit','Balance'] -# type=['string','lable','lable','lable'] -# width=[65,65,65,130] -# else: -# if pattern=='none': -# width=[65,65,65] -# else: -# value=[' ','Debit','Credit','Balance'] -# type=['string','lable','lable','lable'] -# width=[65,65,65,65] -# -# else: -# if perc==1: -# if pattern=='none': -# value=['Balance'] -# type=['lable'] -# width=[130] -# else: -# value=[' ','Balance'] -# type=['string','lable'] -# width=[65,130] -# else: -# if pattern=='none': -# value=['Balance'] -# type=['lable'] -# width=[65] -# else: -# value=[' ','Balance'] -# type=['string','lable'] -# width=[65,65] -# -# if value==['debit','credit','balance']: -# if show==1: -# if perc==1: -# if pattern=='none': -# value=['debit','credit','balance','balance_perc'] -# type=['string','string','string','string'] -# width=[65,65,65,65] -# else: -# value=[pattern,'debit','credit','balance','balance_perc'] -# type=['string','string','string','string','string'] -# width=[65,65,65,65,65] -# else: -# if pattern=='none': -# value=['debit','credit','balance'] -# type=['string','string','string'] -# width=[65,65,65] -# else: -# value=[pattern,'debit','credit','balance'] -# type=['string','string','string','string'] -# width=[65,65,65,65] -# -# else: -# if perc==1: -# if pattern=='none': -# value=['balance','balance_perc'] -# type=['string','string'] -# width=[65,65] -# else: -# value=[pattern,'balance','balance_perc'] -# type=['string','string','string'] -# width=[65,65,65] -# else: -# if pattern=='none': -# value=['balance'] -# type=['string'] -# width=[65] -# else: -# value=[pattern,'balance'] -# type=['string','string'] -# width=[65,65] -# -# if value==['sum_debit','sum_credit','']: -# if show==1: -# if perc==1: -# if pattern=='none': -# width=[65,65,130] -# else: -# value=[' ','sum_debit','sum_credit',''] -# type=['string','string','string','lable'] -# width=[65,65,65,130] -# else: -# if pattern=='none': -# width=[65,65,65] -# else: -# value=[' ','sum_debit','sum_credit',''] -# type=['string','string','string','lable'] -# width=[65,65,65,65] -# else: -# if perc==1: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[130] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,130] -# else: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[65] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,65] -# -# if not lst: -# lst.append(1) -# for ns in node.childNodes : -# if ns and ns.nodeName!='#text' and ns.tagName=='blockTable' and td : -# width_str = ns._attrs['colWidths'].nodeValue -# ns.removeAttribute('colWidths') -# total_td = td * len(value) -# -# if not width: -# for v in value: -# width.append(30) -# check1=0 -# for t in range(td): -# for v in range(len(value)): -# if type[v] in ('String','STRING','string'): -# if (value[v]==" " or value[0]==pattern): -# if check1==0: -# check1=1 -# width_str +=',0.0' -# else: -# width_str +=',%d'%width[v] -# else: -# width_str +=',%d'%width[v] -# else: -# width_str +=',%d'%width[v] -# ns.setAttribute('colWidths',width_str) -# -# child_list = ns.childNodes -# -# check=0 -# for child in child_list: -# if child.nodeName=='tr': -# lc = child.childNodes[1] -# for t in range(td): -# i=0 -# for v in value: -# -# newnode = lc.cloneNode(1) -# temp2="%s['status']==1 and ( setTag('para','para',{'fontName':'Helvetica-bold'})) ]]"%(name) -## -# if type[i] in ('String','STRING','string'): -# if (v==" " or v==pattern) and i==0 and check==0: -# check=1 -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data="" -# else: -# if v==" ": -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data="" -# else: -# t1= "[[ %s['%s%d'] ]]"%(name,v,t) -# if v=="year" or v=="sum_debit" or v=="sum_credit": -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data = t1 -# else: -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data = t1+"[["+temp2 -## newnode.childNodes[1].lastChild.data=[[ a['status']==1 and ( setTag('para','para',{'fontName':'Times-bold'})) ]] -# elif type[i] in ('Lable','LABLE','lable'): -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data= v -# -# child.appendChild(newnode) -# -# newnode=False -# i+=1 -# return super(account_balance_landscape,self).repeatIn(lst, name, nodes_parent=False) -#end def linesForYear(self,form): temp=0 years={} @@ -363,7 +100,6 @@ class account_balance_landscape(rml_parse.rml_parse): total_for_perc=[] -# if perc==1: self.done_total=1 self.total_for_perc=self.linesForTotal(form, ids={}, doneAccount={}, level=1) self.done_total=0 @@ -372,8 +108,6 @@ class account_balance_landscape(rml_parse.rml_parse): locale.setlocale(locale.LC_ALL, '') self.result_total["sum_credit" + str(t1)]=locale.format("%.2f", self.result_total["sum_credit" + str(t1)], grouping=True) self.result_total["sum_debit" + str(t1)]=locale.format("%.2f", self.result_total["sum_debit" + str(t1)], grouping=True) -# self.flag=1 -# self.result_total = {} for temp in range(0,len(form['fiscalyear'])): fy=self.pool.get('account.fiscalyear').name_get(self.cr, self.uid, form['fiscalyear'][temp]) diff --git a/addons/account/report/account_balance_sheet.py b/addons/account/report/account_balance_sheet.py index ab5a284e412..e76c8450573 100644 --- a/addons/account/report/account_balance_sheet.py +++ b/addons/account/report/account_balance_sheet.py @@ -91,7 +91,6 @@ class report_balancesheet_horizontal(rml_parse.rml_parse, common_report_header): ] ctx = self.context.copy() -# ctx['state'] = form['context'].get('state','filter_no') ctx['fiscalyear'] = data['form'].get('fiscalyear_id', False) if data['form']['filter'] == 'filter_period' : diff --git a/addons/account/report/account_report.py b/addons/account/report/account_report.py index 5a62c1ea337..362d0adb414 100644 --- a/addons/account/report/account_report.py +++ b/addons/account/report/account_report.py @@ -122,7 +122,6 @@ class report_aged_receivable(osv.osv): """ This view will be used in dashboard The reason writing this code here is, we need to check date range from today to first date of fiscal year. """ -# ranges = _get_ranges(cr) # Gets the ranges for the x axis of the graph (name column values) pool_obj_fy = pooler.get_pool(cr.dbname).get('account.fiscalyear') today = time.strftime('%Y-%m-%d') fy_id = pool_obj_fy.find(cr, uid, exception=False) diff --git a/addons/account/report/account_report_view.xml b/addons/account/report/account_report_view.xml index 96b49f0247e..a0cee804992 100644 --- a/addons/account/report/account_report_view.xml +++ b/addons/account/report/account_report_view.xml @@ -47,7 +47,6 @@ form tree,graph - @@ -115,9 +114,6 @@ - - - report.account.sales.tree report.account.sales @@ -169,9 +165,7 @@ graph,tree - - report.account_type.sales.tree report.account_type.sales @@ -237,7 +231,6 @@ graph,tree - diff --git a/addons/account/report/compare_account_balance.py b/addons/account/report/compare_account_balance.py index 13fb90fdb5f..b29b2ea4648 100644 --- a/addons/account/report/compare_account_balance.py +++ b/addons/account/report/compare_account_balance.py @@ -58,268 +58,6 @@ class account_balance(report_sxw.rml_parse): }) self.context = context -# def repeatIn(self, lst, name, nodes_parent=False,td=False,width=[],value=[],type=[]): -# self._node.data = '' -# node = self._find_parent(self._node, nodes_parent or parents) -# ns = node.nextSibling -##start -# if value==['Cash','%']: -# if show==1: -# if perc==1: -# if pattern=='none': -# value=['','Cash','%'] -# type=['lable','lable','lable'] -# width=[130,65,65] -# else: -# value=[' ','','Cash','%'] -# type=['string','lable','lable','lable'] -# width=[65,130,65,65] -# else: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[195] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,195] -# else: -# if perc==1: -# if pattern=='none': -# value=['Cash','%'] -# type=['lable','lable'] -# width=[65,65] -# else: -# value=[' ','Cash','%'] -# type=['string','lable','lable'] -# width=[65,65,65] -# else: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[65] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,65] -# -# -# if value==['year']: -# if show==1: -# if perc==1: -# if pattern=='none': -# width=[260] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,260] -# else: -# if pattern=='none': -# width=[195] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,195] -# else: -# if perc==1: -# if pattern=='none': -# width=[130] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,130] -# -# else: -# if pattern=='none': -# width=[65] -# else: -# value=[' ','year'] -# type=['string','string'] -# width=[65,65] -# -# if value==['Debit','Credit','Balance']: -# if show==1: -# if perc==1: -# if pattern=='none': -# width=[65,65,130] -# else: -# value=[' ','Debit','Credit','Balance'] -# type=['string','lable','lable','lable'] -# width=[65,65,65,130] -# else: -# if pattern=='none': -# width=[65,65,65] -# else: -# value=[' ','Debit','Credit','Balance'] -# type=['string','lable','lable','lable'] -# width=[65,65,65,65] -# -# else: -# if perc==1: -# if pattern=='none': -# value=['Balance'] -# type=['lable'] -# width=[130] -# else: -# value=[' ','Balance'] -# type=['string','lable'] -# width=[65,130] -# else: -# if pattern=='none': -# value=['Balance'] -# type=['lable'] -# width=[65] -# else: -# value=[' ','Balance'] -# type=['string','lable'] -# width=[65,65] -# -# if value==['debit','credit','balance']: -# if show==1: -# if perc==1: -# if pattern=='none': -# value=['debit','credit','balance','balance_perc'] -# type=['string','string','string','string'] -# width=[65,65,65,65] -# else: -# value=[pattern,'debit','credit','balance','balance_perc'] -# type=['string','string','string','string','string'] -# width=[65,65,65,65,65] -# else: -# if pattern=='none': -# value=['debit','credit','balance'] -# type=['string','string','string'] -# width=[65,65,65] -# else: -# value=[pattern,'debit','credit','balance'] -# type=['string','string','string','string'] -# width=[65,65,65,65] -# -# else: -# if perc==1: -# if pattern=='none': -# value=['balance','balance_perc'] -# type=['string','string'] -# width=[65,65] -# else: -# value=[pattern,'balance','balance_perc'] -# type=['string','string','string'] -# width=[65,65,65] -# else: -# if pattern=='none': -# value=['balance'] -# type=['string'] -# width=[65] -# else: -# value=[pattern,'balance'] -# type=['string','string'] -# width=[65,65] -# -# if value==['sum_debit','sum_credit','']: -# if show==1: -# if perc==1: -# if pattern=='none': -# width=[65,65,130] -# else: -# value=[' ','sum_debit','sum_credit',''] -# type=['string','string','string','lable'] -# width=[65,65,65,130] -# else: -# if pattern=='none': -# width=[65,65,65] -# else: -# value=[' ','sum_debit','sum_credit',''] -# type=['string','string','string','lable'] -# width=[65,65,65,65] -# else: -# if perc==1: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[130] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,130] -# else: -# if pattern=='none': -# value=[''] -# type=['lable'] -# width=[65] -# else: -# value=[' ',''] -# type=['string','lable'] -# width=[65,65] -# -# if not lst: -# lst.append(1) -# for ns in node.childNodes : -# if ns and ns.nodeName!='#text' and ns.tagName=='blockTable' and td : -# width_str = ns._attrs['colWidths'].nodeValue -# ns.removeAttribute('colWidths') -# total_td = td * len(value) -# -# if not width: -# for v in value: -# width.append(30) -# check1=0 -# for t in range(td): -# for v in range(len(value)): -# if type[v] in ('String','STRING','string'): -# if (value[v]==" " or value[0]==pattern): -# if check1==0: -# check1=1 -# width_str +=',0.0' -# else: -# width_str +=',%d'%width[v] -# else: -# width_str +=',%d'%width[v] -# else: -# width_str +=',%d'%width[v] -# ns.setAttribute('colWidths',width_str) -# -# child_list = ns.childNodes -# -# check=0 -# for child in child_list: -# if child.nodeName=='tr': -# lc = child.childNodes[1] -# for t in range(td): -# i=0 -# for v in value: -# -# newnode = lc.cloneNode(1) -# temp2="%s['status']==1 and ( setTag('para','para',{'fontName':'Helvetica-bold'})) ]]"%(name) -## -# if type[i] in ('String','STRING','string'): -# if (v==" " or v==pattern) and i==0 and check==0: -# check=1 -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data="" -# else: -# if v==" ": -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data="" -# else: -# t1= "[[ %s['%s%d'] ]]"%(name,v,t) -# if v=="year" or v=="sum_debit" or v=="sum_credit": -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data = t1 -# else: -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data = t1+"[["+temp2 -## newnode.childNodes[1].lastChild.data=[[ a['status']==1 and ( setTag('para','para',{'fontName':'Times-bold'})) ]] -# elif type[i] in ('Lable','LABLE','lable'): -# if newnode.childNodes[1].lastChild: -# newnode.childNodes[1].lastChild.data= v -# -# child.appendChild(newnode) -# -# newnode=False -# i+=1 -# return super(account_balance,self).repeatIn(lst, name, nodes_parent=False) -#end - def linesForYear(self, form): temp=0 years={} @@ -363,7 +101,6 @@ class account_balance(report_sxw.rml_parse): total_for_perc=[] -# if perc==1: self.done_total=1 self.total_for_perc=self.linesForTotal(form, ids={}, doneAccount={}, level=1) self.done_total=0 @@ -372,8 +109,6 @@ class account_balance(report_sxw.rml_parse): locale.setlocale(locale.LC_ALL, '') self.result_total["sum_credit" + str(t1)]=locale.format("%.2f", self.result_total["sum_credit" + str(t1)], grouping=True) self.result_total["sum_debit" + str(t1)]=locale.format("%.2f", self.result_total["sum_debit" + str(t1)], grouping=True) -# self.flag=1 -# self.result_total = {} for temp in range(0,len(form['fiscalyear'])): fy=self.pool.get('account.fiscalyear').name_get(self.cr, self.uid, form['fiscalyear'][temp]) diff --git a/addons/account/report/rml_parse.py b/addons/account/report/rml_parse.py index 1b38b930b2b..9178c0fd2e8 100644 --- a/addons/account/report/rml_parse.py +++ b/addons/account/report/rml_parse.py @@ -106,7 +106,6 @@ class rml_parse(report_sxw.rml_parse): return Stringer return Stringer def explode_this(self,chaine,length): - #chaine = self.repair_string(chaine) chaine = rstrip(chaine) ast = list(chaine) i = length @@ -120,7 +119,6 @@ class rml_parse(report_sxw.rml_parse): UnicodeAst = [] _previouslyfound = False i = 0 - #print str(ast) while i < len(ast): elem = ast[i] try: @@ -160,25 +158,5 @@ class rml_parse(report_sxw.rml_parse): rml_head = rml_head.replace('',''' [[company.logo]] ''') return True - # def _add_header(self, node): - # rml_head = tools.file_open('specific_param/report/header/corporate_rml_header_ch.rml').read() - # head_dom = xml.dom.minidom.parseString(rml_head) - # #for frame in head_dom.getElementsByTagName('frame'): - # # frame.parentNode.removeChild(frame) - # node2 = head_dom.documentElement - # for tag in node2.childNodes: - # if tag.nodeType==tag.ELEMENT_NODE: - # found = self._find_node(node, tag.localName) - # # rml_frames = found.getElementsByTagName('frame') - # if found: - # if tag.hasAttribute('position') and (tag.getAttribute('position')=='inside'): - # found.appendChild(tag) - # else: - # found.parentNode.replaceChild(tag, found) - # # for frame in rml_frames: - # # tag.appendChild(frame) - # return True - - # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/account/report/tax_report.py b/addons/account/report/tax_report.py index 2075b1f139b..5e5f68a3fa8 100644 --- a/addons/account/report/tax_report.py +++ b/addons/account/report/tax_report.py @@ -78,7 +78,6 @@ class tax_report(rml_parse.rml_parse): top_result.append(res_general[ind_general]) ind_general+=1 i+=1 - #array_result = self.sort_result(top_result) return top_result #return array_result @@ -133,8 +132,6 @@ class tax_report(rml_parse.rml_parse): company_id, periods_ids,)) res = self.cr.dictfetchall() - #AND line.period_id IN ('+ period_sql_list +') \ - i = 0 while i