From 1a1a37eda58bf7a436bd67178ee981cb763c9394 Mon Sep 17 00:00:00 2001 From: "rpa (Open ERP)" Date: Thu, 29 Jul 2010 18:59:37 +0530 Subject: [PATCH 01/14] [IMP]: sale_crm: Remaining improvement for sales team help on search view bzr revid: rpa@tinyerp.com-20100729132937-93920qo84dhhwqoq --- addons/sale_crm/sale_crm_view.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/sale_crm/sale_crm_view.xml b/addons/sale_crm/sale_crm_view.xml index 4ded6620847..4d393b22435 100644 --- a/addons/sale_crm/sale_crm_view.xml +++ b/addons/sale_crm/sale_crm_view.xml @@ -37,7 +37,7 @@ + help="My Sales Team(s)"/> From 50ee734cae98a03e89c883507d3434a6d8f38c58 Mon Sep 17 00:00:00 2001 From: vra Date: Thu, 29 Jul 2010 19:34:41 +0530 Subject: [PATCH 02/14] [FIX] purchase : Calculation of minimum planned date should not fail when there is no PO Line. bzr revid: vra@tinyerp.com-20100729140441-48kiku916tzfd0mf --- addons/purchase/purchase.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/purchase/purchase.py b/addons/purchase/purchase.py index 2ffdd78e284..e7f5473b42a 100644 --- a/addons/purchase/purchase.py +++ b/addons/purchase/purchase.py @@ -81,7 +81,7 @@ class purchase_order(osv.osv): res={} purchase_obj=self.browse(cr, uid, ids, context=context) for purchase in purchase_obj: - res[purchase.id] = False + res[purchase.id] = time.strftime('%Y-%m-%d %H:%M:%S') if purchase.order_line: min_date=purchase.order_line[0].date_planned for line in purchase.order_line: From 6b7a7edd25712388b1d8d4b1f70a0b79f1a531d7 Mon Sep 17 00:00:00 2001 From: Mantavya Gajjar Date: Thu, 29 Jul 2010 20:56:57 +0530 Subject: [PATCH 03/14] [FIX]: fix a problem of the invoice selection based on the voucher type bzr revid: mga@tinyerp.com-20100729152657-99pz4cuedrbwpymq --- .../account_voucher_payment.py | 31 ++++++++++++++++++- .../account_voucher_payment_view.xml | 4 +-- 2 files changed, 32 insertions(+), 3 deletions(-) diff --git a/addons/account_voucher_payment/account_voucher_payment.py b/addons/account_voucher_payment/account_voucher_payment.py index 3d860146520..dca7eebc977 100755 --- a/addons/account_voucher_payment/account_voucher_payment.py +++ b/addons/account_voucher_payment/account_voucher_payment.py @@ -22,6 +22,35 @@ from osv import fields, osv from tools.translate import _ +class account_invoice(osv.osv): + _inherit = 'account.invoice' + + def search(self, cr, user, args, offset=0, limit=None, order=None, context=None, count=False): + """ + Returns a list of ids based on search domain {args} + + @param cr: A database cursor + @param user: ID of the user currently logged in + @param args: list of conditions to be applied in search opertion + @param offset: default from first record, you can start from nth record + @param limit: number of records to be obtained as a result of search opertion + @param order: ordering on any field(s) + @param context: context arguments, like lang, time zone + @param count: + + @return: Returns a list of ids based on search domain + """ + ttype = context.get('ttype', False) + if ttype and ttype in ('rec_voucher', 'bank_rec_voucher'): + args += [('type','in', ['out_invoice', 'in_refund'])] + elif ttype and ttype in ('pay_voucher', 'bank_pay_voucher'): + args += [('type','in', ['in_invoice', 'out_refund'])] + + res = super(account_invoice, self).search(cr, user, args, offset, limit, order, context, count) + return res + +account_invoice() + class account_move_line(osv.osv): _inherit = "account.move.line" _columns = { @@ -196,7 +225,7 @@ class account_voucher_line(osv.osv): res = super(account_voucher_line, self).move_line_get_item(cr, uid, line, context) res['invoice'] = line.invoice_id or False return res - + def onchange_invoice_id(self, cr, uid, ids, invoice_id, currency_id): currency_pool = self.pool.get('res.currency') invoice_pool = self.pool.get('account.invoice') diff --git a/addons/account_voucher_payment/account_voucher_payment_view.xml b/addons/account_voucher_payment/account_voucher_payment_view.xml index 3f118120c8a..6da4c7d45e2 100755 --- a/addons/account_voucher_payment/account_voucher_payment_view.xml +++ b/addons/account_voucher_payment/account_voucher_payment_view.xml @@ -10,10 +10,10 @@ - + - + From 51eac4e4ece769021af734ed9bb33bfcce41d245 Mon Sep 17 00:00:00 2001 From: Mantavya Gajjar Date: Thu, 29 Jul 2010 21:26:28 +0530 Subject: [PATCH 04/14] [FIX]: further improvement in selection invoice in voucher bzr revid: mga@tinyerp.com-20100729155628-ek5eyvsycwg3y31r --- addons/account_voucher/voucher.py | 2 +- .../account_voucher_payment/account_voucher_payment.py | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/addons/account_voucher/voucher.py b/addons/account_voucher/voucher.py index 0b1b9b01b23..e1005512127 100644 --- a/addons/account_voucher/voucher.py +++ b/addons/account_voucher/voucher.py @@ -203,7 +203,7 @@ class account_voucher(osv.osv): } self.write(cr, uid, ids, res) else: - raise osv.except_osv('Invalid action !', 'You cannot post to Pro-Forma a voucher with Total amount = 0 !') + raise osv.except_osv(_('Invalid action !'), _('You can not post to Pro-Forma a voucher with Total amount = 0 !')) return True def proforma_voucher(self, cr, uid, ids, context={}): diff --git a/addons/account_voucher_payment/account_voucher_payment.py b/addons/account_voucher_payment/account_voucher_payment.py index dca7eebc977..2bae0e6f75a 100755 --- a/addons/account_voucher_payment/account_voucher_payment.py +++ b/addons/account_voucher_payment/account_voucher_payment.py @@ -45,7 +45,10 @@ class account_invoice(osv.osv): args += [('type','in', ['out_invoice', 'in_refund'])] elif ttype and ttype in ('pay_voucher', 'bank_pay_voucher'): args += [('type','in', ['in_invoice', 'out_refund'])] - + elif ttype and ttype in('journal_sale_vou', 'journal_pur_voucher', 'journal_voucher'): + raise osv.except_osv(_('Invalid action !'), _('You can not reconcile sales, purchase, or journal entry with invoice !')) + args += [('type','=', 'do_not_allow_search')] + res = super(account_invoice, self).search(cr, user, args, offset, limit, order, context, count) return res @@ -187,11 +190,12 @@ class account_voucher(osv.osv): move_line_id = move_line_pool.create(cr, uid, move_line) line_ids += [move_line_id] - if line.invoice_id: + if line.invoice_id and inv.type in ('pay_voucher', 'bank_pay_voucher', 'rec_voucher', 'bank_rec_voucher'): rec_ids += [move_line_id] for move_line in line.invoice_id.move_id.line_id: if line.account_id.id == move_line.account_id.id: - rec_ids += [move_line.id] + rec_ids += [move_line.id] + if rec_ids: move_line_pool.reconcile_partial(cr, uid, rec_ids) From 14f89b5b5000c2f1715268322bb7b3c5637d3292 Mon Sep 17 00:00:00 2001 From: Launchpad Code Hosting Date: Fri, 30 Jul 2010 04:37:01 +0100 Subject: [PATCH 05/14] Launchpad automatic translations update. bzr revid: codehost@crowberry-20100730033701-caj9g4wi212iez8m --- addons/account/i18n/et.po | 8 +- addons/base_module_quality/i18n/id.po | 185 ++++++++++++++++++++++++++ addons/sale_layout/i18n/fr.po | 21 ++- 3 files changed, 199 insertions(+), 15 deletions(-) create mode 100644 addons/base_module_quality/i18n/id.po diff --git a/addons/account/i18n/et.po b/addons/account/i18n/et.po index de29b97400e..455b6da50ce 100644 --- a/addons/account/i18n/et.po +++ b/addons/account/i18n/et.po @@ -7,13 +7,13 @@ msgstr "" "Project-Id-Version: OpenERP Server 5.0.0\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-07-22 20:15+0000\n" +"PO-Revision-Date: 2010-07-29 06:54+0000\n" "Last-Translator: lyyser \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-07-23 04:07+0000\n" +"X-Launchpad-Export-Date: 2010-07-30 03:36+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account @@ -6042,12 +6042,12 @@ msgstr "" #. module: account #: wizard_view:account.balance.account.balance.report,init:0 msgid "Select Fiscal Year(s)(Maximum Three Years)" -msgstr "" +msgstr "Vali finantsaasta(d) (maksimum kolm aastat)" #. module: account #: wizard_field:account.balance.account.balance.report,init,select_account:0 msgid "Select Reference Account(for % comparision)" -msgstr "" +msgstr "Valige võrdluskonto (% võrdluseks)" #. module: account #: model:ir.actions.wizard,name:account.wizard_account_balance_report diff --git a/addons/base_module_quality/i18n/id.po b/addons/base_module_quality/i18n/id.po new file mode 100644 index 00000000000..edd55c91ab6 --- /dev/null +++ b/addons/base_module_quality/i18n/id.po @@ -0,0 +1,185 @@ +# Indonesian translation for openobject-addons +# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010 +# This file is distributed under the same license as the openobject-addons package. +# FIRST AUTHOR , 2010. +# +msgid "" +msgstr "" +"Project-Id-Version: openobject-addons\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2009-08-28 16:01+0000\n" +"PO-Revision-Date: 2010-07-29 09:25+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: Indonesian \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2010-07-30 03:37+0000\n" +"X-Generator: Launchpad (build Unknown)\n" + +#. module: base_module_quality +#: field:module.quality.check,final_score:0 +msgid "Final Score (%)" +msgstr "" + +#. module: base_module_quality +#: constraint:ir.model:0 +msgid "" +"The Object name must start with x_ and not contain any special character !" +msgstr "" + +#. module: base_module_quality +#: model:ir.module.module,shortdesc:base_module_quality.module_meta_information +msgid "Base module quality" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.check,name:0 +msgid "Rated Module" +msgstr "" + +#. module: base_module_quality +#: view:module.quality.detail:0 +msgid "Detail" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,note:0 +msgid "Note" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,state:0 +msgid "State" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,detail:0 +msgid "Details" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,ponderation:0 +msgid "Ponderation" +msgstr "" + +#. module: base_module_quality +#: help:module.quality.detail,ponderation:0 +msgid "" +"Some tests are more critical than others, so they have a bigger weight in " +"the computation of final rating" +msgstr "" + +#. module: base_module_quality +#: view:module.quality.check:0 +#: field:module.quality.check,check_detail_ids:0 +msgid "Tests" +msgstr "" + +#. module: base_module_quality +#: selection:module.quality.detail,state:0 +msgid "Skipped" +msgstr "" + +#. module: base_module_quality +#: help:module.quality.detail,state:0 +msgid "" +"The test will be completed only if the module is installed or if the test " +"may be processed on uninstalled module." +msgstr "" + +#. module: base_module_quality +#: constraint:ir.ui.view:0 +msgid "Invalid XML for View Architecture!" +msgstr "" + +#. module: base_module_quality +#: model:ir.model,name:base_module_quality.model_module_quality_check +msgid "module.quality.check" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,name:0 +msgid "Name" +msgstr "" + +#. module: base_module_quality +#: wizard_field:quality_detail_save,init,module_file:0 +msgid "Save report" +msgstr "" + +#. module: base_module_quality +#: wizard_field:quality_detail_save,init,name:0 +msgid "File name" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,score:0 +msgid "Score (%)" +msgstr "" + +#. module: base_module_quality +#: help:quality_detail_save,init,name:0 +msgid "Save report as .html format" +msgstr "" + +#. module: base_module_quality +#: view:module.quality.detail:0 +#: field:module.quality.detail,summary:0 +msgid "Summary" +msgstr "" + +#. module: base_module_quality +#: model:ir.actions.wizard,name:base_module_quality.quality_detail_save +msgid "Report Save" +msgstr "" + +#. module: base_module_quality +#: wizard_view:quality_detail_save,init:0 +msgid "Standard entries" +msgstr "" + +#. module: base_module_quality +#: view:module.quality.detail:0 +msgid "Save Report" +msgstr "" + +#. module: base_module_quality +#: code:addons/base_module_quality/wizard/module_quality_check.py:0 +#: model:ir.actions.wizard,name:base_module_quality.create_quality_check_id +#, python-format +msgid "Quality Check" +msgstr "" + +#. module: base_module_quality +#: model:ir.model,name:base_module_quality.model_module_quality_detail +msgid "module.quality.detail" +msgstr "" + +#. module: base_module_quality +#: selection:module.quality.detail,state:0 +msgid "Done" +msgstr "" + +#. module: base_module_quality +#: code:addons/base_module_quality/speed_test/speed_test.py:0 +#: view:module.quality.check:0 +#: view:module.quality.detail:0 +#, python-format +msgid "Result" +msgstr "" + +#. module: base_module_quality +#: wizard_button:quality_detail_save,init,end:0 +msgid "Cancel" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,message:0 +msgid "Message" +msgstr "" + +#. module: base_module_quality +#: field:module.quality.detail,quality_check_id:0 +msgid "Quality" +msgstr "" diff --git a/addons/sale_layout/i18n/fr.po b/addons/sale_layout/i18n/fr.po index 41c3115135c..8786f6edb7d 100755 --- a/addons/sale_layout/i18n/fr.po +++ b/addons/sale_layout/i18n/fr.po @@ -1,21 +1,20 @@ -# translation of fr_FR.po to Français -# Translation of OpenERP Server. -# This file contains the translation of the following modules: -# * sale_layout +# French translation for openobject-addons +# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010 +# This file is distributed under the same license as the openobject-addons package. +# FIRST AUTHOR , 2010. # -# Numerigraphe , 2009. msgid "" msgstr "" -"Project-Id-Version: fr_FR\n" -"Report-Msgid-Bugs-To: support@openerp.com\n" +"Project-Id-Version: openobject-addons\n" +"Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2009-11-26 08:45+0000\n" -"PO-Revision-Date: 2010-01-19 05:23+0000\n" -"Last-Translator: Numérigraphe \n" -"Language-Team: Français\n" +"PO-Revision-Date: 2010-07-29 08:56+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: French \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-05-21 03:45+0000\n" +"X-Launchpad-Export-Date: 2010-07-30 03:37+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: sale_layout From 86ed2c87a65f734cb1b7d1db00f1e9ab3b333e3d Mon Sep 17 00:00:00 2001 From: Rga <> Date: Fri, 30 Jul 2010 11:36:43 +0530 Subject: [PATCH 06/14] [IMP]:removed unncessary 'nodestroy' from wizard bzr revid: nch@tinyerp.com-20100730060643-qpp6peczbz631gd8 --- .../account/wizard/account_balance_report.py | 2 - addons/account/wizard/account_bs_report.py | 2 - .../account/wizard/account_central_journal.py | 1 - .../account_compare_account_balance_report.py | 8 --- .../account/wizard/account_general_journal.py | 1 - .../wizard/account_general_ledger_report.py | 4 -- .../wizard/account_partner_balance_report.py | 2 - addons/account/wizard/account_pl_report.py | 2 - .../account/wizard/account_print_journal.py | 1 - .../wizard/account_third_party_ledger.py | 3 - addons/account/wizard/account_vat.py | 61 +++++++++---------- .../wizard/account_crossovered_analytic.py | 1 - .../wizard/account_followup_print.py | 1 - .../wizard/hr_payroll_employees_detail.py | 1 - .../wizard/hr_payroll_year_salary.py | 1 - .../marketing_campaign/marketing_campaign.py | 1 - addons/survey/survey.py | 2 - 17 files changed, 30 insertions(+), 64 deletions(-) diff --git a/addons/account/wizard/account_balance_report.py b/addons/account/wizard/account_balance_report.py index 5d02f9fa972..0d2a56d96d6 100644 --- a/addons/account/wizard/account_balance_report.py +++ b/addons/account/wizard/account_balance_report.py @@ -109,7 +109,6 @@ class account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance', 'datas': data, - 'nodestroy':True, } def _check_date(self, cr, uid, data, context=None): @@ -128,7 +127,6 @@ class account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('UserError'),_('Date not in a defined fiscal year')) diff --git a/addons/account/wizard/account_bs_report.py b/addons/account/wizard/account_bs_report.py index dfd035680f2..193e33395f5 100644 --- a/addons/account/wizard/account_bs_report.py +++ b/addons/account/wizard/account_bs_report.py @@ -139,14 +139,12 @@ class account_bs_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.balancesheet.horizontal', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.balancesheet', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('UserError'),_('Date not in a defined fiscal year')) diff --git a/addons/account/wizard/account_central_journal.py b/addons/account/wizard/account_central_journal.py index b1a0f3c2849..dc213f159ab 100644 --- a/addons/account/wizard/account_central_journal.py +++ b/addons/account/wizard/account_central_journal.py @@ -52,7 +52,6 @@ class account_central_journal(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.central.journal', 'datas': datas, - 'nodestroy':True, } account_central_journal() diff --git a/addons/account/wizard/account_compare_account_balance_report.py b/addons/account/wizard/account_compare_account_balance_report.py index af844854271..629e1ae798e 100644 --- a/addons/account/wizard/account_compare_account_balance_report.py +++ b/addons/account/wizard/account_compare_account_balance_report.py @@ -74,14 +74,12 @@ class account_compare_account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance.landscape', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.balance.account.balance', 'datas': data, - 'nodestroy':True, } if data['form']['format_perc']==1: if len(data['form']['fiscalyear'])<=2: @@ -90,14 +88,12 @@ class account_compare_account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance.landscape', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.balance.account.balance', 'datas': data, - 'nodestroy':True, } else: if len(data['form']['fiscalyear'])==3: @@ -106,7 +102,6 @@ class account_compare_account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance.landscape', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('Warning !'), _('You might have done following mistakes. Please correct them and try again. \n 1. You have selected more than 3 years in any case. \n 2. You have not selected Percentage option, but you have selected more than 2 years. \n You can select maximum 3 years. Please check again. \n 3. You have selected Percentage option with more than 2 years, but you have not selected landscape format. You have to select Landscape option. Please Check it.')) @@ -119,7 +114,6 @@ class account_compare_account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance.landscape', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('Warning !'), _('You might have done following mistakes. Please correct them and try again. \n 1. You have selected more than 3 years in any case. \n 2. You have not selected Percentage option, but you have selected more than 2 years. \n You can select maximum 3 years. Please check again. \n 3. You have selected Percentage option with more than 2 years, but you have not selected landscape format. You have to select Landscape option. Please Check it.')) @@ -129,14 +123,12 @@ class account_compare_account_balance_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.account.balance.landscape', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.balance.account.balance', 'datas': data, - 'nodestroy':True, } account_compare_account_balance_report() diff --git a/addons/account/wizard/account_general_journal.py b/addons/account/wizard/account_general_journal.py index 8bd2913ae62..f22846f1637 100644 --- a/addons/account/wizard/account_general_journal.py +++ b/addons/account/wizard/account_general_journal.py @@ -52,7 +52,6 @@ class account_general_journal(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.general.journal', 'datas': datas, - 'nodestroy':True, } account_general_journal() diff --git a/addons/account/wizard/account_general_ledger_report.py b/addons/account/wizard/account_general_ledger_report.py index ad5e74786b0..f8c7794673b 100644 --- a/addons/account/wizard/account_general_ledger_report.py +++ b/addons/account/wizard/account_general_ledger_report.py @@ -107,14 +107,12 @@ class account_general_ledger_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.general.ledger_landscape', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.general.ledger', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('UserError'),_('Date not in a defined fiscal year')) @@ -141,14 +139,12 @@ class account_general_ledger_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.general.ledger_landscape', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.general.ledger', 'datas': data, - 'nodestroy':True, } account_general_ledger_report() diff --git a/addons/account/wizard/account_partner_balance_report.py b/addons/account/wizard/account_partner_balance_report.py index c6d82128256..5d023d8f8ec 100644 --- a/addons/account/wizard/account_partner_balance_report.py +++ b/addons/account/wizard/account_partner_balance_report.py @@ -82,7 +82,6 @@ class account_partner_balance(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.partner.balance', 'datas': data, - 'nodestroy':True, } def _check_date(self, cr, uid, data, context): @@ -98,7 +97,6 @@ class account_partner_balance(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.partner.balance', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('UserError'),_('Date not in a defined fiscal year')) diff --git a/addons/account/wizard/account_pl_report.py b/addons/account/wizard/account_pl_report.py index 9ae7a4dbedf..87f5accf068 100644 --- a/addons/account/wizard/account_pl_report.py +++ b/addons/account/wizard/account_pl_report.py @@ -136,14 +136,12 @@ class account_pl_report(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'pl.account.horizontal', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'pl.account', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('UserError'),_('Date not in a defined fiscal year')) diff --git a/addons/account/wizard/account_print_journal.py b/addons/account/wizard/account_print_journal.py index f40efe3eb99..53c73e66355 100644 --- a/addons/account/wizard/account_print_journal.py +++ b/addons/account/wizard/account_print_journal.py @@ -59,7 +59,6 @@ class account_print_journal(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.journal.period.print', 'datas': datas, - 'nodestroy':True, } account_print_journal() diff --git a/addons/account/wizard/account_third_party_ledger.py b/addons/account/wizard/account_third_party_ledger.py index daff801f3bd..fa40cd0bdc6 100644 --- a/addons/account/wizard/account_third_party_ledger.py +++ b/addons/account/wizard/account_third_party_ledger.py @@ -97,14 +97,12 @@ class account_partner_ledger(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.third_party_ledger', 'datas': data, - 'nodestroy':True, } else: return { 'type': 'ir.actions.report.xml', 'report_name': 'account.third_party_ledger_other', 'datas': data, - 'nodestroy':True, } def _check_date(self, cr, uid, data, context=None): @@ -122,7 +120,6 @@ class account_partner_ledger(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.third_party_ledger', 'datas': data, - 'nodestroy':True, } else: raise osv.except_osv(_('UserError'),_('Date not in a defined fiscal year')) diff --git a/addons/account/wizard/account_vat.py b/addons/account/wizard/account_vat.py index 15c5a55203a..80f4f8360a1 100644 --- a/addons/account/wizard/account_vat.py +++ b/addons/account/wizard/account_vat.py @@ -22,43 +22,42 @@ from osv import osv, fields class account_vat_declaration(osv.osv_memory): - _name = 'account.vat.declaration' - _description = 'Account Vat Declaration' + _name = 'account.vat.declaration' + _description = 'Account Vat Declaration' - _columns = { + _columns = { 'based_on': fields.selection([('invoices','Invoices'), - ('payments','Payments'),], - 'Based On', required=True), + ('payments','Payments'),], + 'Based On', required=True), 'company_id': fields.many2one('res.company', 'Company', required=True), - 'periods': fields.many2many('account.period', 'vat_period_rel', 'vat_id', 'period_id', 'Periods', help="All periods if empty"), - } + 'periods': fields.many2many('account.period', 'vat_period_rel', 'vat_id', 'period_id', 'Periods', help="All periods if empty"), + } - def _get_company(self, cr, uid, context={}): - user_obj = self.pool.get('res.users') - company_obj = self.pool.get('res.company') - user = user_obj.browse(cr, uid, uid, context=context) - if user.company_id: - return user.company_id.id - else: - return company_obj.search(cr, uid, [('parent_id', '=', False)])[0] + def _get_company(self, cr, uid, context={}): + user_obj = self.pool.get('res.users') + company_obj = self.pool.get('res.company') + user = user_obj.browse(cr, uid, uid, context=context) + if user.company_id: + return user.company_id.id + else: + return company_obj.search(cr, uid, [('parent_id', '=', False)])[0] - _defaults = { - 'based_on': 'invoices', - 'company_id': _get_company - } + _defaults = { + 'based_on': 'invoices', + 'company_id': _get_company + } - def create_vat(self, cr, uid, ids, context={}): - if context is None: - context = {} - datas = {'ids': context.get('active_ids', [])} - datas['model'] = 'account.tax.code' - datas['form'] = self.read(cr, uid, ids)[0] - return { - 'type': 'ir.actions.report.xml', - 'report_name': 'account.vat.declaration', - 'datas': datas, - 'nodestroy':True, - } + def create_vat(self, cr, uid, ids, context={}): + if context is None: + context = {} + datas = {'ids': context.get('active_ids', [])} + datas['model'] = 'account.tax.code' + datas['form'] = self.read(cr, uid, ids)[0] + return { + 'type': 'ir.actions.report.xml', + 'report_name': 'account.vat.declaration', + 'datas': datas, + } account_vat_declaration() diff --git a/addons/account_analytic_plans/wizard/account_crossovered_analytic.py b/addons/account_analytic_plans/wizard/account_crossovered_analytic.py index 825ab26aaf9..2429650a800 100644 --- a/addons/account_analytic_plans/wizard/account_crossovered_analytic.py +++ b/addons/account_analytic_plans/wizard/account_crossovered_analytic.py @@ -67,7 +67,6 @@ class account_crossovered_analytic(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account.analytic.account.crossovered.analytic', 'datas': datas, - 'nodestroy': True } account_crossovered_analytic() diff --git a/addons/account_followup/wizard/account_followup_print.py b/addons/account_followup/wizard/account_followup_print.py index 868249365ee..c3fd73370eb 100644 --- a/addons/account_followup/wizard/account_followup_print.py +++ b/addons/account_followup/wizard/account_followup_print.py @@ -304,7 +304,6 @@ class account_followup_print_all(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'account_followup.followup.print', 'datas': datas, - 'nodestroy': True } account_followup_print_all() diff --git a/addons/hr_payroll/wizard/hr_payroll_employees_detail.py b/addons/hr_payroll/wizard/hr_payroll_employees_detail.py index 314dcfa94bb..c2d0e3c4116 100755 --- a/addons/hr_payroll/wizard/hr_payroll_employees_detail.py +++ b/addons/hr_payroll/wizard/hr_payroll_employees_detail.py @@ -63,7 +63,6 @@ class hr_payroll_employees_detail(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'employees.salary', 'datas': datas, - 'nodestroy':True, } hr_payroll_employees_detail() diff --git a/addons/hr_payroll/wizard/hr_payroll_year_salary.py b/addons/hr_payroll/wizard/hr_payroll_year_salary.py index 0445d559f58..a7091540894 100755 --- a/addons/hr_payroll/wizard/hr_payroll_year_salary.py +++ b/addons/hr_payroll/wizard/hr_payroll_year_salary.py @@ -65,7 +65,6 @@ class hr_payroll_year_salary(osv.osv_memory): 'type': 'ir.actions.report.xml', 'report_name': 'year.salary', 'datas': datas, - 'nodestroy':True, } hr_payroll_year_salary() diff --git a/addons/marketing_campaign/marketing_campaign.py b/addons/marketing_campaign/marketing_campaign.py index 46e1e28ade7..787557145e3 100644 --- a/addons/marketing_campaign/marketing_campaign.py +++ b/addons/marketing_campaign/marketing_campaign.py @@ -674,7 +674,6 @@ class marketing_campaign_workitem(osv.osv): 'type' : 'ir.actions.report.xml', 'report_name': wi_obj.activity_id.report_id.report_name, 'datas' : datas, - 'nodestroy': True, } else: raise osv.except_osv(_('No preview'),_('The current step for this item has no email or report to preview.')) diff --git a/addons/survey/survey.py b/addons/survey/survey.py index 8cac202fe40..a78fe55ea2d 100644 --- a/addons/survey/survey.py +++ b/addons/survey/survey.py @@ -124,7 +124,6 @@ class survey(osv.osv): 'type': 'ir.actions.report.xml', 'report_name': 'survey.browse.response', 'datas': datas, - 'nodestroy': True, 'context' : context } else: @@ -135,7 +134,6 @@ class survey(osv.osv): 'type': 'ir.actions.report.xml', 'report_name': 'survey.form', 'datas': datas, - 'nodestroy':True, 'context' : context } return report From 46eda1ff973d5c1964c6283078ae06c2923acb89 Mon Sep 17 00:00:00 2001 From: "rpa (Open ERP)" Date: Fri, 30 Jul 2010 12:42:41 +0530 Subject: [PATCH 07/14] [IMP]: crm: Put warning on lead creation for stage in comment bzr revid: rpa@tinyerp.com-20100730071241-sip39pg464ss1u5a --- addons/crm/crm_lead.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/addons/crm/crm_lead.py b/addons/crm/crm_lead.py index 0ad779d403f..56a30c4791a 100644 --- a/addons/crm/crm_lead.py +++ b/addons/crm/crm_lead.py @@ -164,8 +164,9 @@ class crm_lead(osv.osv, crm_case): } def create(self, cr, uid, vals, context=None): - if not vals.get('stage_id',False): - raise osv.except_osv('Error', _('There is no stage defined for this Sales Team')) +# FIXME: Do we really need this? if yes, this is not a correct way to check for stage +# if not vals.get('stage_id',False): +# raise osv.except_osv('Error', _('There is no stage defined for this Sales Team')) return super(crm_lead, self).create(cr, uid, vals, context=context) def onchange_partner_address_id(self, cr, uid, ids, add, email=False): From 9a245f625aa8aab3dbb1ccb9faf0581851dc681c Mon Sep 17 00:00:00 2001 From: "RME(OpenERP)" <> Date: Fri, 30 Jul 2010 13:22:45 +0530 Subject: [PATCH 08/14] [IMP] Icon improvements lp bug: https://launchpad.net/bugs/610845 fixed bzr revid: jvo@tinyerp.com-20100730075245-f0ehjauj3pq8oumy --- addons/account/account_invoice_view.xml | 4 ++-- addons/account/account_view.xml | 12 ++++++------ addons/account/wizard/account_invoice_state_view.xml | 2 +- .../account/wizard/account_journal_select_view.xml | 2 +- .../wizard/account_move_bank_reconcile_view.xml | 2 +- addons/account/wizard/account_move_journal_view.xml | 2 +- .../account_move_line_reconcile_select_view.xml | 2 +- .../account/wizard/account_move_line_select_view.xml | 2 +- .../account_move_line_unreconcile_select_view.xml | 2 +- .../wizard/account_open_closed_fiscalyear_view.xml | 2 +- .../wizard/account_partner_balance_report_view.xml | 2 +- addons/account/wizard/account_use_model_view.xml | 2 +- addons/account_voucher/voucher_view.xml | 4 ++-- addons/crm_claim/report/crm_claim_report_view.xml | 2 +- .../report/crm_fundraising_report_view.xml | 2 +- .../hr_holidays/report/hr_holidays_report_view.xml | 2 +- .../hr_timesheet_sheet/hr_timesheet_sheet_view.xml | 2 +- addons/lunch/lunch_view.xml | 2 +- 18 files changed, 25 insertions(+), 25 deletions(-) diff --git a/addons/account/account_invoice_view.xml b/addons/account/account_invoice_view.xml index ac82fc1b6cc..22df9059305 100644 --- a/addons/account/account_invoice_view.xml +++ b/addons/account/account_invoice_view.xml @@ -138,7 +138,7 @@