Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Access One2many field from onchange in v9

By
Matthew Watkins
on 7/27/16, 7:32 PM 319 views

I am trying to do the exact same thing that was addressed in this post, except in version 9.

https://www.odoo.com/fr_FR/forum/aide-1/question/access-one2many-list-in-many2one-onchange-event-93056

I tried implementing the v7 patch code here, but it won't work in 9.

Thanks.

I get this error:

Odoo Server Error

Traceback (most recent call last):

File "/opt/odoo/openerp/http.py", line 643, in _handle_exception

return super(JsonRequest, self)._handle_exception(exception)

File "/opt/odoo/openerp/http.py", line 680, in dispatch

result = self._call_function(**self.params)

File "/opt/odoo/openerp/http.py", line 316, in _call_function

return checked_call(self.db, *args, **kwargs)

File "/opt/odoo/openerp/service/model.py", line 118, in wrapper

return f(dbname, *args, **kwargs)

File "/opt/odoo/openerp/http.py", line 309, in checked_call

result = self.endpoint(*a, **kw)

File "/opt/odoo/openerp/http.py", line 959, in __call__

return self.method(*args, **kw)

File "/opt/odoo/openerp/http.py", line 509, in response_wrap

response = f(*args, **kw)

File "/opt/odoo/addons/web/controllers/main.py", line 892, in call_kw

return self._call_kw(model, method, args, kwargs)

File "/opt/odoo/addons/web/controllers/main.py", line 884, in _call_kw

return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)

File "/opt/odoo/openerp/api.py", line 250, in wrapper

return old_api(self, *args, **kwargs)

File "/opt/odoo/openerp/api.py", line 381, in old_api

result = method(recs, *args, **kwargs)

File "/opt/odoo/addons/project_emp_team/models/project_emp_team.py", line 71, in onchange

match = onchange_v7.match(field_onchange[field_name])

TypeError: unhashable type: 'list'

Matthew Watkins
on 7/27/16, 7:38 PM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 7/27/16, 7:32 PM
Seen: 319 times
Last updated: 7/28/16, 1:11 AM