Odoo Help


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.


Dynamic Value in selection field

Umashankar Subramani
on 12/31/15, 4:28 AM 567 views


   I need a selection field with dynamic value based on another field,

My scenario is,

  1)Need to select Discount range with min and max value(many2one field)

  2)In the selection field dropdown i need only the selected range of values 



Please give me some suggestion.............


Tarek Mohamed Ibrahim

--Tarek Mohamed Ibrahim--
| 5 3 7
Gîza, Egypt
--Tarek Mohamed Ibrahim--

I am an old VFP developer on ERP

I have moved to 2p since Nov-2014 and started developing with Python on Odoo.



Tarek Mohamed Ibrahim
On 1/3/16, 8:55 PM

If he used in the xml view the widget


then the field would appear same as a selection field even if it comes from a table or a collected items via a function field, and the user then can use domains to change values dynamically

On 1/3/16, 11:39 AM

Hi , 

You can not create dynamic selection field because values are loaded at form load and can`t be changed but you can create many2one (with create=False) field and use domain to change values dynamically.

Thanks Yogesh i got that in many2one field, by using name_get function

Umashankar Subramani
on 1/3/16, 11:39 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)


Asked: 12/31/15, 4:28 AM
Seen: 567 times
Last updated: 1/3/16, 8:55 PM