Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1 Відповісти
4655 Переглядів

If you want to prevent users from creating new records from a relational field

Аватар
Відмінити

You can do it dynamically based on each model and its fields (relational fields) in v16 and v17: https://apps.odoo.com/apps/modules/17.0/mh_dynamic_many2one_field_options

Автор Найкраща відповідь

If you want to prevent users from creating new records from a relational field (just like the country_id field on the res.partner model), just add this in the xml view: options="{"no_open": True, "no_create": True}".

For example:

.

will prevent users from creating new roles from the x_role_id field.

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
1
січ. 25
10182
1
трав. 21
2370
1
квіт. 21
8546
2
січ. 25
6117
4
груд. 24
16777