콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
3 답글
4593 화면

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'
아바타
취소

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

작성자

I am comment the security csv from manifest everything ok,

베스트 답변

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>

아바타
취소
작성자

not working bro,

Absolutely not, the problem occurs with version 10.

ok :(

관련 게시물 답글 화면 활동
3
2월 19
10666
0
4월 15
3227
1
8월 18
14814
2
6월 17
30171
1
2월 16
2254