'data': [
'security/groups.xml',
'security/ir.model.access.csv',
'views/library_book.xml'
],
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!-- 權限模型 -->
<record id="model_permission" model="ir.model">
<field name="name">Model Permission</field>
<field name="model">model.permission</field>
<field name="state">manual</field>
</record>
<!-- 權限設定 -->
<record id="permission_read" model="model.permission">
<field name="name">Read Model Data</field>
<field name="model_id" ref="base.model_name" />
<field name="perm_read" eval="1" />
<field name="perm_create" eval="0" />
<field name="perm_write" eval="0" />
<field name="perm_unlink" eval="0" />
<field name="group_id" ref="base.group_user" />
</record>
<record id="permission_create" model="model.permission">
<field name="name">Create Model Data</field>
<field name="model_id" ref="base.model_name" />
<field name="perm_read" eval="0" />
<field name="perm_create" eval="1" />
<field name="perm_write" eval="0" />
<field name="perm_unlink" eval="0" />
<field name="group_id" ref="base.group_manager" />
</record>
<!-- 更多權限設定可以在這裡添加 -->
</odoo>
明天介紹怎麼分類群組