c2c-oerpscenario team mailing list archive
-
c2c-oerpscenario team
-
Mailing list archive
-
Message #14670
[Bug 711194] [NEW] [6.0.1] many2one fields on search screen with a particular domain cause web client errors
Public bug reported:
I have a search screen with partner_id and partner_contact_id fields on
it.
The partner_contact_id field has a domain set as
[('partner_id','=',partner_id)]
On normal form screens, this domain correctly filters the contacts by
partner. However on the search screen an error is generated in the web
client when I try to change the value in the field:
expr_eval Error while parsing "[('partner_id','=',partner_id)]"
Traceback (most recent call last):
File "/usr/local/bin/openerp6/web/addons/openerp/utils/tools.py", line 50, in expr_eval
temp = eval(string, context)
File "<string>", line 1, in <module>
NameError: name 'partner_id' is not defined
In addition, the popup search window crashes with the following
exception:
HTTP Traceback (most recent call last):
File "/usr/local/bin/openerp6/web/lib/cherrypy/_cprequest.py", line 606, in respond
cherrypy.response.body = self.handler()
File "/usr/local/bin/openerp6/web/lib/cherrypy/_cpdispatch.py", line 25, in __call__
return self.callable(*self.args, **self.kwargs)
File "/usr/local/bin/openerp6/web/openobject/tools/_expose.py", line 182, in func_wrapper
res = func(*args, **kw)
File "/usr/local/bin/openerp6/web/openobject/controllers/_root.py", line 87, in default
return request.handler()
File "/usr/local/bin/openerp6/web/lib/cherrypy/_cpdispatch.py", line 25, in __call__
return self.callable(*self.args, **self.kwargs)
File "/usr/local/bin/openerp6/web/addons/openerp/controllers/utils.py", line 112, in wrapper
return fn(*args, **kw)
File "/usr/local/bin/openerp6/web/openobject/tools/_expose.py", line 182, in func_wrapper
res = func(*args, **kw)
File "/usr/local/bin/openerp6/web/addons/openerp/controllers/search.py", line 89, in new
params.domain.append(('id','in', params.ids))
AttributeError: 'dict' object has no attribute 'append'
I can work around this issue by removing the domain from the field just
on search views, so not a major problem, but just so you are aware.
** Affects: openobject-client-web
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/711194
Title:
[6.0.1] many2one fields on search screen with a particular domain
cause web client errors
Status in OpenERP Web Client:
New
Bug description:
I have a search screen with partner_id and partner_contact_id fields
on it.
The partner_contact_id field has a domain set as
[('partner_id','=',partner_id)]
On normal form screens, this domain correctly filters the contacts by
partner. However on the search screen an error is generated in the web
client when I try to change the value in the field:
expr_eval Error while parsing "[('partner_id','=',partner_id)]"
Traceback (most recent call last):
File "/usr/local/bin/openerp6/web/addons/openerp/utils/tools.py", line 50, in expr_eval
temp = eval(string, context)
File "<string>", line 1, in <module>
NameError: name 'partner_id' is not defined
In addition, the popup search window crashes with the following
exception:
HTTP Traceback (most recent call last):
File "/usr/local/bin/openerp6/web/lib/cherrypy/_cprequest.py", line 606, in respond
cherrypy.response.body = self.handler()
File "/usr/local/bin/openerp6/web/lib/cherrypy/_cpdispatch.py", line 25, in __call__
return self.callable(*self.args, **self.kwargs)
File "/usr/local/bin/openerp6/web/openobject/tools/_expose.py", line 182, in func_wrapper
res = func(*args, **kw)
File "/usr/local/bin/openerp6/web/openobject/controllers/_root.py", line 87, in default
return request.handler()
File "/usr/local/bin/openerp6/web/lib/cherrypy/_cpdispatch.py", line 25, in __call__
return self.callable(*self.args, **self.kwargs)
File "/usr/local/bin/openerp6/web/addons/openerp/controllers/utils.py", line 112, in wrapper
return fn(*args, **kw)
File "/usr/local/bin/openerp6/web/openobject/tools/_expose.py", line 182, in func_wrapper
res = func(*args, **kw)
File "/usr/local/bin/openerp6/web/addons/openerp/controllers/search.py", line 89, in new
params.domain.append(('id','in', params.ids))
AttributeError: 'dict' object has no attribute 'append'
I can work around this issue by removing the domain from the field
just on search views, so not a major problem, but just so you are
aware.
Follow ups
References