From 367706427455a68b17dff1980aefc7666db38127 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Wed, 5 Oct 2011 17:35:39 +0200 Subject: [PATCH 01/37] [IMP] notification: warnings does not expire bzr revid: chs@openerp.com-20111005153539-xxds5bog4p08m2yl --- addons/web/static/src/js/chrome.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index dae7ba62ceb..579a95b1bad 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -28,7 +28,9 @@ openerp.web.Notification = openerp.web.Widget.extend(/** @lends openerp.web.Not warn: function(title, text) { this.$element.notify('create', 'oe_notification_alert', { title: title, - text: text + text: text, + }, { + expires: false, }); } }); From f995b029adb9e7a37e793caaadad9008aaaf40bb Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Tue, 11 Oct 2011 16:16:10 +0530 Subject: [PATCH 02/37] [Fix] Stock:In menu Warehouse/Reporting/Last Product Inventories user can filter list of record by Consumable button lp bug: https://launchpad.net/bugs/872184 fixed bzr revid: aag@tinyerp.com-20111011104610-me91ssg9nnom2dgu --- addons/stock/report/report_stock_view.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/stock/report/report_stock_view.xml b/addons/stock/report/report_stock_view.xml index 829fae14b6b..fe49e8eae9f 100644 --- a/addons/stock/report/report_stock_view.xml +++ b/addons/stock/report/report_stock_view.xml @@ -38,7 +38,7 @@ + domain="[('product_id.type','=', 'consu')]"/> From 31c8d4240fc023500127ea61361a0fed98333abb Mon Sep 17 00:00:00 2001 From: Amit Parik <> Date: Tue, 11 Oct 2011 16:35:22 +0530 Subject: [PATCH 03/37] [FIX] point_of_sale : wrong domain in POS for 'Products 'Take Money Out' and Products 'Put Money In' lp bug: https://launchpad.net/bugs/871689 fixed bzr revid: bde@tinyerp.com-20111011110522-tdslg58i2q7wd15c --- addons/point_of_sale/point_of_sale_view.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/point_of_sale/point_of_sale_view.xml b/addons/point_of_sale/point_of_sale_view.xml index 4f1019e602e..65b356b3845 100644 --- a/addons/point_of_sale/point_of_sale_view.xml +++ b/addons/point_of_sale/point_of_sale_view.xml @@ -670,7 +670,7 @@ product.product form tree,form - [('income_pdt','=',True)] + [('expense_pdt','=',True)] @@ -696,7 +696,7 @@ product.product form tree,form - [('expense_pdt','=',True)] + [('income_pdt','=',True)] From f5290738fa20c06cba644b7a8a00397fc9acf826 Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Tue, 11 Oct 2011 18:17:59 +0530 Subject: [PATCH 04/37] [Fix] mrp_repair:when Repair Orders confirmed state is Confirmed to Repair lp bug: https://launchpad.net/bugs/872253 fixed bzr revid: aag@tinyerp.com-20111011124759-3981imbw2kjklk5f --- addons/mrp_repair/mrp_repair.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 6e5543dbadd..ce5c21b5f53 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -122,7 +122,7 @@ class mrp_repair(osv.osv): 'prodlot_id': fields.many2one('stock.production.lot', 'Lot Number', select=True, domain="[('product_id','=',product_id)]"), 'state': fields.selection([ ('draft','Quotation'), - ('confirmed','Confirmed, to repair'), + ('confirmed','Confirmed to Repair'), ('ready','Ready to Repair'), ('under_repair','Under Repair'), ('2binvoiced','To be Invoiced'), From b720f12d55724d6a91a4847b9b1cf516b265f1cb Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Wed, 12 Oct 2011 11:34:26 +0530 Subject: [PATCH 05/37] [Fix] Purchase:In Purchases/Reporting/Purchase Analysis search view Category,Reference UOM Buttons Icons are changed lp bug: https://launchpad.net/bugs/872677 fixed bzr revid: aag@tinyerp.com-20111012060426-czoq7wdwbsppjkzh --- addons/purchase/report/purchase_report_view.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/purchase/report/purchase_report_view.xml b/addons/purchase/report/purchase_report_view.xml index d0b0c13c211..f947857a016 100644 --- a/addons/purchase/report/purchase_report_view.xml +++ b/addons/purchase/report/purchase_report_view.xml @@ -99,8 +99,8 @@ - - + + From da939a215aca097e534bb76d3a3e5b7e0aa4c6ef Mon Sep 17 00:00:00 2001 From: Mustufa Rangwala <> Date: Wed, 12 Oct 2011 12:08:00 +0530 Subject: [PATCH 06/37] [FIX] account : in bank statement form when i tried to import invoice from button import invoices lp bug: https://launchpad.net/bugs/867461 fixed bzr revid: bde@tinyerp.com-20111012063800-p72utna4b9olsbeu --- addons/account_voucher/account_voucher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account_voucher/account_voucher.py b/addons/account_voucher/account_voucher.py index 005e5d9ab46..f609192ade8 100644 --- a/addons/account_voucher/account_voucher.py +++ b/addons/account_voucher/account_voucher.py @@ -1056,7 +1056,7 @@ class account_bank_statement_line(osv.osv): for obj in self.browse(cr, uid, ids, context=context): if obj.voucher_id: diff = abs(obj.amount) - obj.voucher_id.amount - if not self.pool.get('res.currency').is_zero(cr, uid, obj.voucher_id.currency_id, diff): + if not self.pool.get('res.currency').is_zero(cr, uid, obj.statement_id.currency, diff): return False return True From ecab5ad2862d771948cd59b80536e5e67b4bdbf0 Mon Sep 17 00:00:00 2001 From: "Kirti Savalia (OpenERP)" Date: Wed, 12 Oct 2011 13:04:12 +0530 Subject: [PATCH 07/37] [FIX]:pass the missing context in product_id_change method lp bug: https://launchpad.net/bugs/872689 fixed bzr revid: ksa@tinyerp.com-20111012073412-h7k3tr07bcy2vpup --- addons/warning/warning.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/warning/warning.py b/addons/warning/warning.py index ab7a5926653..9f699ab9911 100644 --- a/addons/warning/warning.py +++ b/addons/warning/warning.py @@ -197,7 +197,7 @@ class sale_order_line(osv.osv): def product_id_change(self, cr, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, - fiscal_position=False, flag=False): + fiscal_position=False, flag=False, context=None): warning = {} if not product: return {'value': {'th_weight' : 0, 'product_packaging': False, @@ -232,7 +232,7 @@ class purchase_order_line(osv.osv): _inherit = 'purchase.order.line' def product_id_change(self,cr, uid, ids, pricelist, product, qty, uom, partner_id, date_order=False, fiscal_position=False, date_planned=False, - name=False, price_unit=False, notes=False): + name=False, price_unit=False, notes=False, context=None): warning = {} if not product: return {'value': {'price_unit': 0.0, 'name':'','notes':'', 'product_uom' : False}, 'domain':{'product_uom':[]}} From 948b05507e5d501cd55f2d4fb55db7fb42095b63 Mon Sep 17 00:00:00 2001 From: "Kirti Savalia (OpenERP)" Date: Wed, 12 Oct 2011 14:19:01 +0530 Subject: [PATCH 08/37] [FIX]:Group By state in analytic accounts lp bug: https://launchpad.net/bugs/872695 fixed bzr revid: ksa@tinyerp.com-20111012084901-9ym5207s34wogit7 --- addons/account/project/project_view.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/account/project/project_view.xml b/addons/account/project/project_view.xml index 54abae1d992..5e0c4acbcbe 100644 --- a/addons/account/project/project_view.xml +++ b/addons/account/project/project_view.xml @@ -65,6 +65,7 @@ + From 486068af6bd8879c8d986dc64fbdd6149584995d Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Wed, 12 Oct 2011 15:02:38 +0530 Subject: [PATCH 09/37] [IMP] mrp_repair:change state name Confirmed to Repair ==> To Repair bzr revid: aag@tinyerp.com-20111012093238-2u82cugba2fd3336 --- addons/mrp_repair/mrp_repair.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index ce5c21b5f53..77164049390 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -122,7 +122,7 @@ class mrp_repair(osv.osv): 'prodlot_id': fields.many2one('stock.production.lot', 'Lot Number', select=True, domain="[('product_id','=',product_id)]"), 'state': fields.selection([ ('draft','Quotation'), - ('confirmed','Confirmed to Repair'), + ('confirmed','To Repair'), ('ready','Ready to Repair'), ('under_repair','Under Repair'), ('2binvoiced','To be Invoiced'), From ddd6c53d256aaf17a6800ed9a3a0b95fa880a06a Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Wed, 12 Oct 2011 15:12:40 +0530 Subject: [PATCH 10/37] [IMP] mrp_repair:change state name To Repair to confirmed bzr revid: aag@tinyerp.com-20111012094240-pr4yenhrkqm5o738 --- addons/mrp_repair/mrp_repair.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 77164049390..18979e998bd 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -122,7 +122,7 @@ class mrp_repair(osv.osv): 'prodlot_id': fields.many2one('stock.production.lot', 'Lot Number', select=True, domain="[('product_id','=',product_id)]"), 'state': fields.selection([ ('draft','Quotation'), - ('confirmed','To Repair'), + ('confirmed','Confirmed'), ('ready','Ready to Repair'), ('under_repair','Under Repair'), ('2binvoiced','To be Invoiced'), From 8cf348cc570433934348c9c50852b1e3a415b613 Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Thu, 13 Oct 2011 08:56:11 +0200 Subject: [PATCH 11/37] [IMP] account, financial.report object: added translate=True on 'name' field bzr revid: qdp-launchpad@openerp.com-20111013065611-ibvbezd2hthzr3v9 --- addons/account/account.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account/account.py b/addons/account/account.py index a9111e12bb1..ebc1f23a44d 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -2719,7 +2719,7 @@ class account_financial_report(osv.osv): return res _columns = { - 'name': fields.char('Report Name', size=128, required=True), + 'name': fields.char('Report Name', size=128, required=True, translate=True), 'parent_id': fields.many2one('account.financial.report', 'Parent'), 'children_ids': fields.one2many('account.financial.report', 'parent_id', 'Account Report'), 'sequence': fields.integer('Sequence'), From e7075a939d87f65925809f6624d8a330bc19bfff Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Thu, 13 Oct 2011 09:10:04 +0200 Subject: [PATCH 12/37] [FIX] product: usability fix lp bug: https://launchpad.net/bugs/872201 fixed bzr revid: qdp-launchpad@openerp.com-20111013071004-9pm5ci3pac0kylna --- addons/product/product_view.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/product/product_view.xml b/addons/product/product_view.xml index 35798ce939d..254a75fdcdc 100644 --- a/addons/product/product_view.xml +++ b/addons/product/product_view.xml @@ -10,7 +10,7 @@ - + From d29aa739714271757986160358e6856438a7b691 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Thu, 13 Oct 2011 10:13:51 +0200 Subject: [PATCH 13/37] [IMP] allow controller functions to return werkzeug.exceptions.HTTPException (i.e. 404 errors) bzr revid: chs@openerp.com-20111013081351-layprblm1dt140py --- addons/web/common/http.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/addons/web/common/http.py b/addons/web/common/http.py index 453484acee7..314ac8ce717 100644 --- a/addons/web/common/http.py +++ b/addons/web/common/http.py @@ -227,7 +227,7 @@ class HttpRequest(WebRequest): _logger.debug("%s --> %s.%s %r", self.httprequest.method, controller.__class__.__name__, method.__name__, akw) r = method(controller, self, **self.params) if self.debug or 1: - if isinstance(r, werkzeug.wrappers.BaseResponse): + if isinstance(r, (werkzeug.wrappers.BaseResponse, werkzeug.exceptions.HTTPException)): _logger.debug('<-- %s', r) else: _logger.debug("<-- size: %s", len(r)) @@ -395,7 +395,8 @@ class Root(object): else: response = result - response.set_cookie(self.session_cookie, session.sid) + if hasattr(response, 'set_cookie'): + response.set_cookie(self.session_cookie, session.sid) return response(environ, start_response) From a58395f2af3181bf94738a6cfcfa7c691172437a Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Thu, 13 Oct 2011 10:14:45 +0200 Subject: [PATCH 14/37] [FIX] do no load the menu until a session is active [IMP] make menu loading hookable bzr revid: chs@openerp.com-20111013081445-1xzvodzrtxvacbzz --- addons/web/static/src/js/chrome.js | 4 ++-- addons/web/static/src/js/views.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index 1742bd91c95..dae7ba62ceb 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -788,9 +788,8 @@ openerp.web.Menu = openerp.web.Widget.extend(/** @lends openerp.web.Menu# */{ }, start: function() { this.$secondary_menu.addClass(this.folded ? 'oe_folded' : 'oe_unfolded'); - this.reload(); }, - reload: function() { + do_reload: function() { this.rpc("/web/menu/load", {}, this.on_loaded); }, on_loaded: function(data) { @@ -972,6 +971,7 @@ openerp.web.WebClient = openerp.web.Widget.extend(/** @lends openerp.web.WebClie this.menu.start(); }, on_logged: function() { + this.menu.do_reload(); if(this.action_manager) this.action_manager.stop(); this.action_manager = new openerp.web.ActionManager(this); diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index 593e5cab116..006213086be 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -124,7 +124,7 @@ db.web.ActionManager = db.web.Widget.extend({ if (this.dialog && action.context) { var model = action.context.active_model; if (model === 'base.module.upgrade' || model === 'base.setup.installer') { - db.webclient.menu.reload(); + db.webclient.menu.do_reload(); } } this.dialog_stop(); From 2be7586c542d4ebd6cddebb1105ab65ec899c785 Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Thu, 13 Oct 2011 11:34:23 +0200 Subject: [PATCH 15/37] [FIX] fields.related: fix example in docstring bzr revid: qdp-launchpad@openerp.com-20111013093423-lynuxoan01327jv9 --- openerp/osv/fields.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openerp/osv/fields.py b/openerp/osv/fields.py index 11f24f14505..d0be75a012f 100644 --- a/openerp/osv/fields.py +++ b/openerp/osv/fields.py @@ -1037,7 +1037,7 @@ class related(function): _columns = { 'foo_id': fields.many2one('my.foo', 'Foo'), - 'bar': fields.related('frol', 'foo_id', type='char', string='Frol of Foo'), + 'bar': fields.related('foo_id', 'frol', type='char', string='Frol of Foo'), } """ From 60c780120020403ede5cb1997f5508983c642109 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Thu, 13 Oct 2011 11:36:56 +0200 Subject: [PATCH 16/37] [fix] some inconsistencies in context in a view in hr_recruitment bzr revid: nicolas.vanhoren@openerp.com-20111013093656-f04vuvyl0wxihh86 --- addons/hr_recruitment/hr_recruitment_view.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/hr_recruitment/hr_recruitment_view.xml b/addons/hr_recruitment/hr_recruitment_view.xml index e5905b16a77..3310dbcf4ef 100644 --- a/addons/hr_recruitment/hr_recruitment_view.xml +++ b/addons/hr_recruitment/hr_recruitment_view.xml @@ -89,7 +89,8 @@