تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
4668 أدوات العرض

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.

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
1
يناير 25
10203
1
مايو 21
2380
1
أبريل 21
8577
2
يناير 25
6123
4
ديسمبر 24
16828