Skip to Content
Menu
This question has been flagged
3 Replies
3540 Views

where is wrong, is my code 

ir.model.access.csv

id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink

access_battery_rent,battery.rent.account.user,battery.rent.model_battery_rent,group_pyth_disciple,1,1,1,1


and security.xml

<?xml version="1.0" encoding="utf-8"?>

<odoo>

    <data>

        <record id="group_pyth_disciple" model="res.groups">

            <field name="name">Maintenance Battery Rent</field>

        </record>

    </data>

</odoo>

error
File "D:\openAps\odoo10\Scripts\odoo-10\odoo\api.py", line 760, in __getitem__
    return self.registry[model_name]._browse((), self)
  File "D:\openAps\odoo10\Scripts\odoo-10\odoo\modules\registry.py", line 178, in __getitem__
    return self.models[model_name]
KeyError: u'odoo'
Avatar
Discard

If you comment the security csv file from manifest, does it make any difference?

Author

I am comment the security csv from manifest everything ok,

Best Answer

Replace odoo to openerp: hope this will hepls

<openerp>

    <data>

        <record id="group_pyth_disciple" model="res.groups">

            <field name="name">Maintenance Battery Rent</field>

        </record>

    </data>

</openerp>

Avatar
Discard
Author

not working bro,

Absolutely not, the problem occurs with version 10.

ok :(

Related Posts Replies Views Activity
3
Feb 19
9481
0
Apr 15
2199
1
Aug 18
13257
2
Jun 17
27216
1
Feb 16
2254