تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
6624 أدوات العرض

I am new to Qweb templating and following the code in Odoo Development Essentials, I am adding a Kanban view to my project. The program works till i add the following line to my code:

                              <t t-foreach="record.message_follower_ids.raw_value" t-as="rec">                                       

                                  <t t-esc="rec" />;
                               </t>

Then my browser shows the following error:


Odoo Client Error

Error: QWeb2 - template['kanban-box']: Runtime Error: TypeError: dict.record.message_follower_ids is undefined

http://localhost:8069/web/js/web.assets_common/ca89443:1020

الصورة الرمزية
إهمال
أفضل إجابة

Can you please refere this line : https://github.com/odoo/odoo/blob/8.0/addons/note/note_view.xml#L83

May be you have not added field like : https://github.com/odoo/odoo/blob/8.0/addons/note/note_view.xml#L52

الصورة الرمزية
إهمال
الكاتب

Thanks. Your answer was helpful. I needed to declare the fields to be used in the kanban template before using them in the template.

المنشورات ذات الصلة الردود أدوات العرض النشاط
2
ديسمبر 24
1562
0
مايو 23
3632
0
يونيو 20
14509
0
يونيو 20
2797
1
يونيو 15
10670