Odoo Help


how can i create dropdown box in openerp?

on 1/22/14, 2:08 AM 4,567 views

about dropdown box

shashank verma
On 1/22/14, 2:27 AM

Hi satish U can do this in 2ways by using selection field and many2one field. By using selection field u can create your own options in list menu. To access option list from other table use many2one.

In .py file

my_item:fields.selection((('pendrive','pendrive'),('fan','fan'),('lamp','lamp')),'My Items')


In xml file

<field name="my_item" widget="selection/"> <field name="erp_item" widget="selection/">

Remember widget is mandatory for man2one if u want to use it as a drop down list.

Dr Obx
On 4/5/15, 5:49 PM

Dropdown box is simple but create a many2one is a little bit more complicated. That's what i'm looking for :)

About This Community

This platform 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.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

0 follower(s)


Asked: 1/22/14, 2:08 AM
Seen: 4567 times
Last updated: 5/20/16, 12:24 PM