Onchange features

Asked by Buyanbat on 2010-08-17

So I have two fields. Field-A is selection and Field-B is many2one and using selection method. When I change Field-A, I want to change Field-B's selection lists by onchange method (options on HTML). Is that possible? I tried it by few method. (changed Field-B's domain values on onchange method of Field-A, change Field-B's selection(s) on onchange method of Field-A) But could not make something happen.
IS THAT POSSIBLE?
Sorry my bad English.

Question information

Language:
English Edit question
Status:
Solved
For:
Odoo Server (MOVED TO GITHUB) Edit question
Assignee:
No assignee Edit question
Solved by:
Buyanbat
Solved:
2010-08-17
Last query:
2010-08-17
Last reply:
2010-08-17
Navrang Oza (noz-tiny) said : #1

I think is not related to web client now.
Is it ?

Buyanbat (buyanbat-ch) said : #2

I think so.
But I can return any value from server on onchange method (like {'value': blah, 'domain': blah, 'selection': blah}).
And I never use gtk-client. Just have to improve web-client.

Navrang Oza (noz-tiny) said : #3

But to confirm, you have to check in GTK too.
Because if the same problem is there in GTK also then problem may be from server side.
Not from web client.

You should check in GTK too.

Navrang Oza (noz-tiny) said : #4

You can return result in list of tuple from onchange for selection field.

Anup(SerpentCS) (anup-serpent) said : #5

Hello Buyanbat,

  We can not have an on_change method for selection field. And its not the problem of web-client. It's a server issue.

Thanks.

ksh (Axelor) (ksh-axelor) said : #6

Hello there,
           This feature is supported in stable-eTiny but not in gtk, return list of tuple for target selection field(Field-B) on onchange of Field-A.

Buyanbat (buyanbat-ch) said : #7

I know GTK-Client. It is more suitable and user friendlier than web client.
I think we can return on_change dict.