dev-resources.site
for different kinds of informations.
Odoo User Permission and groups
Published at
7/3/2024
Categories
odoo
Author
Jeevachaithanyan Sivanandan
Categories
1 categories in total
odoo
open
I was trying to add a new set of permission after technical in user profile page.
But I could not find the code in the odoo folder, all I have got is below
<record id="user_groups_view" model="ir.ui.view">
<field name="name">res.users.groups</field>
<field name="model">res.users</field>
<field name="inherit_id" ref="view_users_form"/>
<field name="arch" type="xml">
<!-- dummy, will be modified by groups -->
<field name="groups_id" position="after"/>
</field>
</record>
I was enthralled why I dont see any text for technical but later realized its autogenerated bu groups. So in order to create new permissions, we need to create our custom group-
In Odoo, to refer the groups category created by odoo, check this page
odoo\odoo\addons\base\data\ir_module_category_data.xml
example on how to add custom permission inside this category - odoo\addons\product\security\product_security.xml
<?xml version="1.0" encoding="utf-8"?>
<record id="group_product_pricelist" model="res.groups">
<field name="name">Basic Pricelists</field>
<field name="category_id" ref="base.module_category_hidden"/>
</record>
<record id="group_sale_pricelist" model="res.groups">
<field name="name">Advanced Pricelists</field>
<field name="category_id" ref="base.module_category_hidden"/>
<field name="implied_ids" eval="[(4, ref('product.group_product_pricelist'))]"/>
</record>
Articles
12 articles in total
Python Program for a Turing Machine Simulator python Copy code
read article
Install Odoo v 17 with Python 3.12 in MSWindows 11
read article
Boosting Code Quality in Odoo with Type Hints: Benefits Beyond Performance
read article
Odoo: Import CSV file and write into sale order lines
read article
Odoo : create CSV file and download
read article
Odoo : how to create a Wizard with download a file and auto close
read article
How to Configure Multiple Conditions in Odoo XML Views
read article
Odoo : Patch a Javascript class
read article
how to create new permission groups, permission category
read article
Odoo User Permission and groups
currently reading
extended unpacking in Python
read article
odoo v14 and issues with requirements.txt
read article
Featured ones: