Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
4440 Widoki

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

Awatar
Odrzuć

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

Autor Najlepsza odpowiedź

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.

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
1
sty 25
9916
1
maj 21
2218
1
kwi 21
8315
2
sty 25
5921
4
gru 24
16382