Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
3 Ответы
4078 Представления

I want to disable quick create and create and edit option that is available in the Sales module. Kindly guide

Аватар
Отменить
Лучший ответ

If you want to do it globally, best to find an add-on.  Here are some that are available:

web_m2x_options

Restrict Quick Creation/Edition Many2one Field

Many2one Field Configuration

Аватар
Отменить

Also add in the above list: https://apps.odoo.com/apps/modules/17.0/mh_dynamic_many2one_field_options
this will do it dynamically model and field based.

Лучший ответ

Hi 

You can use create="0" and edit="0" in the view to disable create and edit options.

Here Inherit the sale order tree view and apply these attributes


Regards

Аватар
Отменить
Лучший ответ

Hi,

This is possible using no_quick_create and no_create_edit .Options are following,
no_quick_create - It will remove the Create "entered text" option.
no_create_edit - It will remove the Create and edit... option.
no_create - no_quick_create and no_create_edit combined.
no_open - in read mode: do not render as a link.

1. Activate developer mode -> sale -> debug -> Edit form view2. Add the following options to the field do you want to prevent quick create and create and edit option.
options="{'no_create_edit': True, 'no_quick_create': True}"3. Save
for example

<field name="your_field name" options="{'no_quick_create':True,'no_create_edit':True}"/>


Hope it helps

Аватар
Отменить