V9에서 작동하는 버전 9 modu가 있습니다. V10에 설치하고 오류를 얻으려고합니다. 보안 그룹을 만들 때 오류가 발생합니다. 나는 또한 메인 테이너 툴인 V10으로 마이그레이션을 시도했다. 내가 서버를 중지하고 시작하는 경우 다음 Odoo 9 모듈 - V10
> Replace openerp imports to odoo.
>
> Rename __openerp__.py to __manifest__.py
>
> Replace select = True by index = TrueReplace string selectors in XML by name (if possible) or other attribute selector or even another
> equivalent path/reference. For example, change <group string="x"
> position="after"> by <group name="x" position="after">Remove <data>
> and </data> in xml files if noupdate="0"
>
> Replace the <openerp>/</openerp> tags in xml files by <odoo>/</odoo>.
>
> Don't use @api.one with @api.onchange or it will crash.
>
> ...
오류
File "/home/jason/git/odoo10/odoo/addons/base/ir/ir_model.py", line 1028, in xmlid_lookup
raise ValueError('External ID not found in the system: %s' % xmlid)
ParseError: "<type 'exceptions.ValueError'>: "External ID not found in the system: base.group_sale_salesman_all_leads" while evaluating
"[(4,ref('base.group_user')), (4,ref('account.group_account_invoice')), (4,ref('stock.group_stock_user')), (4,ref('base.group_sale_salesman_all_leads'))]"" while parsing /home/jason/git/customaddons/layby_order/security/layby_security.xml:5, near
<record id="group_layby_user" model="res.groups">
<field name="name">Layby User</field>
<field name="category_id" ref="base.module_category_sales_management"/>
<field name="comment">This is applicable for Layby User.</field>
<field name="implied_ids" eval="[(4,ref('base.group_user')), (4,ref('account.group_account_invoice')), (4,ref('stock.group_stock_user')), (4,ref('base.group_sale_salesman_all_leads'))]"/>
</record>
layby_security.xml
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<record id="group_layby_user" model="res.groups">
<field name="name">Layby User</field>
<field name="category_id" ref="base.module_category_sales_management"/>
<field name="comment">This is applicable for Layby User.</field>
<field name="implied_ids" eval="[(4,ref('base.group_user')),
(4,ref('account.group_account_invoice')),
(4,ref('stock.group_stock_user')),
(4,ref('base.group_sale_salesman_all_leads'))]"/>
</record>
</data>
</openerp>
ir.model.access.csv
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_layby_order,layby.order,model_layby_order,group_layby_user,1,1,1,0
access_layby_order_line,layby.order.line,model_layby_order_line,group_layby_user,1,1,1,1
입니다 다시 시도한 다음 설치를 시도하십시오.
File "/home/jason/git/customaddons/layby_order/layby.py", line 147
date_order = fields.Date.context_today(self)
SyntaxError: invalid syntax
그 후 설치하면 Parse 오류 외부 ID를 찾을 수 없습니다. 설치가 147 행에 멈추고 있기 때문에 내가 그 이유를 생각하고있다. date_order = fields.Date.context_today(self)
그러나 나는 이유를 모른다.
147
date_order = fields.Date.context_today(self))
사라하지만 지금 V9에서 모듈을 마이그레이션 할
raise Exception(_('Module loading %s failed: file %s could not be processed:\n %s') % (module, fname, warning_msg))
Exception: Module loading layby_order failed: file layby_order/security/ir.model.access.csv could not be processed:
No matching record found for external id 'model_layby_order' in field 'Object'
Missing required value for the field 'Object' (model_id)
No matching record found for external id 'model_layby_order_line' in field 'Object'
Missing required value for the field 'Object' (model_id)
원래 질문을 업데이트했습니다. ir.model.access.csv를 처리 할 수없는 다른 오류가 발생했습니다. 아직 date_order = fields.Date.context_today (self)에서 중지 중입니다. – user2379186
답변을 업데이트했습니다! 도움이되는지 알려주세요. –
ParseError :/home/jason/git/customaddons/layby_order /를 구문 분석하는 동안 ValueError ('시스템에서 외부 ID를 찾을 수 없습니다 : % s'% xmlid) ParseError : "시스템에 외부 ID가 없습니다 : layby_order.model_layby_order" security/layby_security.xml : 5, – user2379186