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

Hi,

I was editing Odoo product page design and added small part of the code trough "HTML/CSS Editor", once i saved the page I got following error:

'NoneType' object has no attribute 'product_id'
Traceback (most recent call last):
  File "/opt/odoo/odoo/addons/base/ir/ir_qweb/qweb.py", line 343, in _compiled_fn
    return compiled(self, append, new, options, log)
  File "<template>", line 1, in template_784_86982
  File "<template>", line 2, in body_call_content_86981
AttributeError: 'NoneType' object has no attribute 'product_id'

Error to render compiling AST
AttributeError: 'NoneType' object has no attribute 'product_id'
Template: 784
Path: /templates/t/t/div/section/div/div[2]/form/div/ul
Node: <ul t-foreach="l.product_id.attribute_value_ids" t-as="attrib_value">
    <li t-esc=" '%s: %s' % (attrib_value.attribute_id.name, attrib_value.name)"/>
</ul>

now the page wont load so I can opne that HTML/CSS Editor again in order to fix the page and remove that code again. How can I access that editor again?

Thanks for your help!

الصورة الرمزية
إهمال

Hi,

search in the source code for l.product_id.attribute_value_ids, with an IDE like eclipse, or with linux command line ack to search in files. If your modification has been made in temporary file with your html editor (no precision for what editor you used, how ..), perhaps also delete your browser cache.

Bye

أفضل إجابة

You may update the website_sale module. Next time you should create a custom module to change any views, and use the HTML/CSS editor for testing purposes on a test installation only, as your changes will get overridden when updating the website or website_sale module.

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
1
ديسمبر 19
6928
0
مارس 15
4024
3
مارس 24
1930
1
أبريل 24
2098
2
مارس 24
3279