OSError:找不到文件:library_app\security\library_security.xml
我正在尝试升级我的模块,但我遇到了这个问题。
这是我的清单
{
'name': 'Library Management',
'description': 'Manage library book catalogue and lending',
'author': 'Nicolas Rondon',
'depends': ['base'],
'application': True,
'data': [
'security/library_security.xml',
'security/ir.model.access.csv',
'views/library_menu.xml',
]
}
xml
<?xml version="1.0"?>
<odoo>
<record id="module_library_category" model="ir.module.category">
<field name="name">Library</field>
</record>
<!-- Library User Group -->
<record id="library_group_user" model="res.groups">
<field name="name">User</field>
<field name="category_id"
ref="module_library_category"/>
<field name="implied_ids"
eval="[(4, ref('base.group_user'))]"/>
</record>
<!-- Library Manager Group -->
<record id="library_group_manager" model="res.groups">
<field name="name">Manager</field>
<field name="category_id"
ref="module_library_category"/>
<field name="implied_ids"
eval="[(4, ref('library_group_user'))]"/>
<field name="users"
eval="[(4, ref('base.user_root')),
(4, ref('base.user_admin'))]"/>
</record>
</odoo>
实际上我正在关注Odoo-12-Development-Essentials-Fourth-Edition来学习 Odoo。所以我的代码和书很相似。