Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
6 ตอบกลับ
8100 มุมมอง

how can i remove different Actions from specific modules?

e.a. "Send SMS" from Partners or "Share" from Invoices.

we use Odoo V12 Community

ths solutions i found in forum seems to work only in older Odoo versions

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi

You can do it just by adding group into action record

For example by Interface you can do it by access Setting->Technical->Window Actions menu, and search for "Send SMS"

Then you can add some group that granted to access that following action in "Group" tab (picture below)


 

And if you understand to updating record from xml file, surely you can do it so by xml file (for developer user)


For example:

<record model="ir.actions.act_window" id="sms.send_sms_action">
    <field name="groups_id" eval="[(4,ref('base.group_private_addresses'))]" />
</record>


Regards
La Jayuhni Yarsyah

อวตาร
ละทิ้ง
ผู้เขียน

i could remove the send SMS but with the Share action it does not work (portal.portal_share_action).

คำตอบที่ดีที่สุด

I wrote a module 'web_menu_action_if' to accomplish this task in Odoo 9.0.
See my answer to:

https://www.odoo.com/forum/help-1/question/assign-action-menu-item-to-specific-tree-view-112007

อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด

@\Dhaval Desai: Your links referr to removing menu items. i want to remove Action-Items in the Action-Dropdown that is on to of most tree views

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hello @ jack,

you can see below links:
1.)  https://stackoverflow.com/questions/33908406/remove-or-hide-a-menu-item-in-odoo

2.)  https://odooforbeginnersblog.wordpress.com/2017/02/28/how-to-create-to-hide-a-menu-item-in-odoo/

Thank You.

อวตาร
ละทิ้ง