If you want to prevent users from creating new records from a relational field
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Účetnictví
- Sklad
- PoS
- Project
- MRP
This question has been flagged
1
Odpovědět
4419
Zobrazení
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.
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Přihlásit seRelated Posts | Odpovědi | Zobrazení | Aktivita | |
---|---|---|---|---|
|
1
led 25
|
9885 | ||
|
1
kvě 21
|
2202 | ||
|
1
dub 21
|
8280 | ||
|
2
led 25
|
5885 | ||
|
4
pro 24
|
16329 |
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