I have created a new Groups which is a Personnel Group, But in the View Metadata the new Group I've created has no XML ID, where can I find the XML ID or add the XML ID of the new groups even in the external ID menu I cannot find the ID.
-
might be this will helpful you in future http://stackoverflow.com/questions/22368935/openerp-7-how-to-give-users-access-to-custom-module-in-openerp-7/22534350#22534350 – Bhavesh Odedra Oct 05 '15 at 14:41
3 Answers
How to create or edit custom groups:
- open Settings->Users->Groups
- select some group "Custom User Groups / ..." or create new one and set value "Custom User Groups" for "Application" field
- click "edit"
- add or delete inherited groups in "Inherited" tab
- click "save"
How to apply groups for some users:
- open Settings->Users->Users
- select user you need
- click "clear access rights"
- tick access groups you need. In the main, you have to use only ones from "Custom User Groups" sector, because all inherited tick boxes will be ticked automatically, after you click save.
- click save
Please note, that if you delete some technical group from custom group, then you have to repeat process of applying groups for each related users. If you don't repeat applying process then removed group would be kept in related users, because there is no way to figure out is it was added by inheritance or manually as a extra access to that user.
I managed to do it with a few hours of searching in the XMLs:
This is a Example of Security Group Create
security/ng_office_technology_security:
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data noupdate="0">
<record id="office_technology_group" model="res.groups">
<field name="name">Office technology</field>
<field name="comment">Office Technology Permission Group.</field>
<field name="category_id" ref="ng_office_technology.module_category_ng_office_technology"/>
</record>
<record model="ir.module.category" id="module_category_ng_office_technology">
<field name="name">Office Technology</field>
<field name="description">The Office technology Applilcation</field>
<field name="sequence">20</field>
</record>
</data>
</openerp>

- 2,284
- 1
- 15
- 35
If you have created group manualy from UI it will not show the xml id because record is not created by xml record. if the record is created by the demo data(xml) it will show the XML ID of the record
for example,
<record id="user_group_id" model="res.groups">
<field name="name">User Group</field>
<field name="category_id" ref="base.module_category_sales_management"/>
</record>
Here user_group_id
is your xml id. All the xml id is stored in ir_model_data
table or 'ir.model.data'.
You can find under Settings > Technical > Sequences & Identifiers > External identifiers
hope this helps.

- 16,054
- 6
- 50
- 58
-
what is the base.module_category_sales_management? is that the parent group because my personnel group is under the HR group.. – Black and White Oct 06 '15 at 01:33
-
It is a ir.module.category defined in base, for HR you can put base.module_category_human_resources. – Atul Arvind Oct 06 '15 at 03:11
-
That is a nice answer, but what if he (or another one) can't create custom modules (e.g. no server access). You can ofcourse create your own external identifier under Settings > Technical > Sequences & Identifiers > External identifiers. You just need the real id of your created group. – CZoellner Oct 06 '15 at 08:28
-
You can export all groups data from debug mode, and that will give you an id of UI-created group. That id looks strange but still usable. – Summer Sun Mar 04 '16 at 03:02
1.Go to settings>Users>Groups>
2.Find your group
3.Edit and go on the "Views" tab.
4.If you have defined any view then you will find it here along with External ID
otherwise you can add a new one from existing views.
Turn on the developer mode from "About Odoo" under your profile icon if you need to.

- 313
- 2
- 10