Skip to Content
Menu
This question has been flagged
2 Replies
7395 Views

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!

Avatar
Discard

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

Best Answer

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.

Avatar
Discard
Related Posts Replies Views Activity
1
Dec 19
5578
0
Mar 15
4000
3
Mar 24
447
1
Apr 24
1096
2
Mar 24
2230