私は odoo を初めて使用します。sales_order を継承してモジュールを作成し、カスタム レポートを作成しました。レポートを印刷すると、上記のエラーが発生します。助けが必要ですか?
コード スニペットは次のとおりです。
テスト/my_module.py:
class sale_order(models.Model):
_name = 'sale.order'
_description = 'Inheritance'
_inherit = 'sale.order'
test/views/report_template_view.xml:
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<template id="test_report">
<t t-call="report.html_container">
<t t-call="report.internal_layout">
<t t-set="doc" t-value="doc.with_context({'lang':doc.partner_id.lang})"/>
<div class="page">
<div class="oe_structure"/>
<div> <strong><left>User</left></strong>
<p t-field="doc.user_id"/>
</div>
</div>
</t>
</t>
</template>
</data>
のレコードにアクセスするにはどうすればよいcustom_report_template
ですか?