Templates 奥多<;t-call=";网站.版面「&燃气轮机;qWebException
当我添加到我的模板时,我得到以下错误Templates 奥多<;t-call=";网站.版面「&燃气轮机;qWebException,templates,web,odoo,openerp-8,Templates,Web,Odoo,Openerp 8,当我添加到我的模板时,我得到以下错误 QWebException: "'NoneType' object has no attribute 'name'" while evaluating 'res_company.name' 模板代码: <template id="index" > <t t-call="website.layout"> <t t-set="title">Academy</t>
QWebException: "'NoneType' object has no attribute 'name'" while evaluating
'res_company.name'
模板代码:
<template id="index" >
<t t-call="website.layout">
<t t-set="title">Academy</t>
<div class="oe_structure">
<div class="container">
<ul><t t-foreach="brands" t-as="b">
<li><a t-attf-href="/pa/{{b.id}}">
<t t-esc="b.name"/>
</a></li>
</t></ul>
</div>
</div>
</t>
</template>
学院
问题出在控制器上,我必须附加网址=True
@http.route('/pa/', auth='public', website=True)
您可以发布您在所示模板中使用的模型结构的代码吗?这将为确定问题提供更好的思路。是的,你知道为什么需要这样做吗?老而金,先生,你是一个典范