Odoo Help


3 Answers
Jaakko Komulainen
20‏/5‏/2014 5:14 ص

You can set it in xml by inheriting the original view and setting the required attribute of a field.

<field name="property_account_position" position="attributes">

    <attribute name="required">True</attribute>



1 Comment
13‏/7‏/2016 12:06 ص

if we inheriting this original view, is necessary use the <xpath>?

Jérôme Thériault
3‏/4‏/2017 4:01 م
  • Go into the view in developper mode.

  • In the debug menu, select edit view

  • In the dialog, select "Inherited views" and click Add new. This creates a new inherited view in the database, so you don't need to develope a whole module.

  • Give it a name you'll recognize. Could be anything but for uniformity, I suggest you follow what other views do.

  • Set the inheritance mode to Extension View

  • In the architecture field, enter what you'd normally enter in a XML view file. See below for an example:


<field name="street" position="attributes">

  <attribute name="required">True</attribute>



Ask a Question
Keep Informed
1 follower(s)
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