Onchange features

Asked by Buyanbat

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:
Last query:
Last reply:
Revision history for this message
Navrang Oza (noz-tiny) said :
#1

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

Revision history for this message
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.

Revision history for this message
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.

Revision history for this message
Navrang Oza (noz-tiny) said :
#4

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

Revision history for this message
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.

Revision history for this message
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.

Revision history for this message
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.