将消息添加到视图时,视图架构无效 XML
Invalid XML for View Architecture when adding messages into views
我想将消息添加到我的模块中,
我继承了mail.threadclass:
inherit= ['mail.thread','ir.needaction_mixin']
并制作了所需的依赖项:
'depends': ['base','mail']
一切正常,但是当我添加这四行代码以将消息添加到我的模块中时:
<record id="travel_info_view" model="ir.ui.view">
<field name="name">travel.info.view</field>
<field name="type">form</field>
<field name="model">travel.info</field>
<field name="arch" type="xml">
<form string="travel.info" version="7.0">
<sheet>
----
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
<field name="message_ids" widget="mail_thread"/>
</div>
</form>
</field>
</record>
出现错误:
('ValidateError',u'验证字段 arch 时发生错误:视图架构无效 XML!')
这是什么原因??
我发现了错误,是继承的拼写错误
我写了:
继承= ['mail.thread','ir.needaction_mixin']
正确的是:
_inherit = 'mail.thread'
我想将消息添加到我的模块中, 我继承了mail.threadclass:
inherit= ['mail.thread','ir.needaction_mixin']
并制作了所需的依赖项:
'depends': ['base','mail']
一切正常,但是当我添加这四行代码以将消息添加到我的模块中时:
<record id="travel_info_view" model="ir.ui.view">
<field name="name">travel.info.view</field>
<field name="type">form</field>
<field name="model">travel.info</field>
<field name="arch" type="xml">
<form string="travel.info" version="7.0">
<sheet>
----
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
<field name="message_ids" widget="mail_thread"/>
</div>
</form>
</field>
</record>
出现错误: ('ValidateError',u'验证字段 arch 时发生错误:视图架构无效 XML!')
这是什么原因??
我发现了错误,是继承的拼写错误
我写了:
继承= ['mail.thread','ir.needaction_mixin']
正确的是:
_inherit = 'mail.thread'