From 44294ac056fcd32ce4308d54ead7774b605825aa Mon Sep 17 00:00:00 2001 From: "RGA(OpenERP)" <> Date: Wed, 17 Mar 2010 19:34:54 +0530 Subject: [PATCH 01/12] Improved related changes for browse support in reference field bzr revid: hda@tinyerp.com-20100317140454-r70kmvakhw3rrv80 --- bin/addons/base/ir/ir_ui_menu.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/bin/addons/base/ir/ir_ui_menu.py b/bin/addons/base/ir/ir_ui_menu.py index 78c86a8569e..e242de45802 100644 --- a/bin/addons/base/ir/ir_ui_menu.py +++ b/bin/addons/base/ir/ir_ui_menu.py @@ -100,9 +100,7 @@ class ir_ui_menu(osv.osv): if menu.action: # we check if the user has access to the action of the menu - m, oid = menu.action.split(',', 1) - data = self.pool.get(m).browse(cr, 1, int(oid)) - + data = menu.action if data: model_field = { 'ir.actions.act_window': 'res_model', 'ir.actions.report.custom': 'model', @@ -111,7 +109,7 @@ class ir_ui_menu(osv.osv): 'ir.actions.server': 'model_id', } - field = model_field.get(m) + field = model_field.get(menu.action._name) if field and data[field]: if not modelaccess.check(cr, uid, data[field], raise_exception=False): continue From a87d74b385a64ee3409b134ddc3aed00a338f35f Mon Sep 17 00:00:00 2001 From: "Harry (Open ERP)" Date: Thu, 18 Mar 2010 21:00:43 +0530 Subject: [PATCH 02/12] [FIX] dms: if file does not has any direcotry on creation, take root directory bzr revid: hmo@tinyerp.com-20100318153043-32ict1bcx08pe704 --- addons/document/document.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/document/document.py b/addons/document/document.py index 375f24cd62a..f3ffd2f6f6c 100644 --- a/addons/document/document.py +++ b/addons/document/document.py @@ -157,6 +157,8 @@ class document_file(osv.osv): context = {} vals['title'] = vals['name'] vals['parent_id'] = context.get('parent_id', False) or vals.get('parent_id', False) + if not vals['parent_id']: + vals['parent_id'] = self.pool.get('document.directory')._get_root_directory(cr,uid, context) if not vals.get('res_id', False) and context.get('default_res_id', False): vals['res_id'] = context.get('default_res_id', False) if not vals.get('res_model', False) and context.get('default_res_model', False): From 85bc0eea767b825c257b1afe08c05fd21c38ccee Mon Sep 17 00:00:00 2001 From: Stephane Wirtel Date: Thu, 18 Mar 2010 17:53:53 +0100 Subject: [PATCH 03/12] [FIX] osv.fields: Remove the limit lp bug: https://launchpad.net/bugs/541015 fixed bzr revid: stephane@openerp.com-20100318165353-it4l18yzx6lbxmg1 --- bin/osv/fields.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/osv/fields.py b/bin/osv/fields.py index 19735857680..475c3234705 100644 --- a/bin/osv/fields.py +++ b/bin/osv/fields.py @@ -366,7 +366,7 @@ class one2many(_column): _prefetch = False _type = 'one2many' - def __init__(self, obj, fields_id, string='unknown', limit=20, **args): + def __init__(self, obj, fields_id, string='unknown', limit=None, **args): args.update({'parent_field':fields_id}) _column.__init__(self, string=string, **args) self._obj = obj From d4d1302faeb9c691a71d4e014d8b13d85815ae34 Mon Sep 17 00:00:00 2001 From: Stephane Wirtel Date: Thu, 18 Mar 2010 18:55:06 +0100 Subject: [PATCH 04/12] [FIX] netrpc_server: Use the logging module bzr revid: stephane@openerp.com-20100318175506-i10u5oaj02i4hbz9 --- bin/service/netrpc_server.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/service/netrpc_server.py b/bin/service/netrpc_server.py index 6260ec3d0e5..9a8a699cb76 100644 --- a/bin/service/netrpc_server.py +++ b/bin/service/netrpc_server.py @@ -30,6 +30,7 @@ import os import socket import tiny_socket + class TinySocketClientThread(threading.Thread, netsvc.OpenERPDispatcher): def __init__(self, sock, threads): threading.Thread.__init__(self) @@ -119,8 +120,8 @@ class TinySocketServerThread(threading.Thread,netsvc.Server): "Netrpc: %d threads" % len(self.threads)) self.socket.close() except Exception, e: - netsvc.Logger().notifyChannel("web-services", netsvc.LOG_WARNING, - "Netrpc: closing because of exception %s" % str(e)) + import logging + logging.getLogger('web-services').warning("Netrpc: closing because of exception %s" % str(e)) self.socket.close() return False From 986a1dbdbf2793ba0d205d6feaf730d0bbafbc0c Mon Sep 17 00:00:00 2001 From: Julien Thewys Date: Thu, 18 Mar 2010 23:44:32 +0100 Subject: [PATCH 05/12] [FIX] Fixed comma and colon in workflow string generation. bzr revid: jth@openerp.com-20100318224432-w0t81ok5hh3fdlla --- addons/base_module_record/base_module_record.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/base_module_record/base_module_record.py b/addons/base_module_record/base_module_record.py index e80a43ad1c8..8f69d082f26 100644 --- a/addons/base_module_record/base_module_record.py +++ b/addons/base_module_record/base_module_record.py @@ -447,7 +447,7 @@ class workflow(yaml.YAMLObject): self.ref = ref self.action=action def __repr__(self): - return '!workflow {model: %s, action: %s ref: %s}:' % (str(self.model,), str(self.action,), str(self.ref,)) + return '!workflow {model: %s, action: %s, ref: %s}' % (str(self.model,), str(self.action,), str(self.ref,)) class ref(yaml.YAMLObject): yaml_tag = u'!ref' From 9881a90a9f95cf2ea060e3aeee7eb65b6a22762e Mon Sep 17 00:00:00 2001 From: "mra (Open ERP)" Date: Fri, 19 Mar 2010 09:53:34 +0530 Subject: [PATCH 06/12] [FIX] hr_evaluation: Mission date file on terp bzr revid: mra@tinyerp.com-20100319042334-hnl0cafhievtrylh --- addons/hr_evaluation/__terp__.py | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/hr_evaluation/__terp__.py b/addons/hr_evaluation/__terp__.py index 26b71c795c8..6472bc80496 100644 --- a/addons/hr_evaluation/__terp__.py +++ b/addons/hr_evaluation/__terp__.py @@ -32,7 +32,6 @@ "update_xml" : [ "security/ir.model.access.csv", "hr_evaluation_view.xml", - "hr_evaluation_data.xml", "report/hr_evaluation_report_view.xml"], "active": False, "installable": True From 92f3fde4ac487e3add2e553c9d4769eb210d7366 Mon Sep 17 00:00:00 2001 From: "Jay (Open ERP)" Date: Fri, 19 Mar 2010 11:35:37 +0530 Subject: [PATCH 07/12] [FIX] CRM : Meeting View had additional state field lp bug: https://launchpad.net/bugs/541456 fixed bzr revid: jvo@tinyerp.com-20100319060537-1ph9utsglcr26gh8 --- addons/crm/crm_meeting_view.xml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/addons/crm/crm_meeting_view.xml b/addons/crm/crm_meeting_view.xml index a1f1cef502e..8161b504306 100644 --- a/addons/crm/crm_meeting_view.xml +++ b/addons/crm/crm_meeting_view.xml @@ -148,8 +148,7 @@ - - +