Hello,
i had suddenly this error in my database (odoo 8.0):
Field(s) `arch` failed against a constraint: Invalid view definition
Error details:
Element '<xpath expr="//header//a[@class='navbar-brand']">' cannot be located in parent view
Error context:
View `Show Logo`
[view_id: 846, xml_id: website.layout_logo_show, model: n/a, parent_id: 844]" while parsing None:173, near
<data inherit_id="website.layout" customize_show="True" name="Show Logo">
<xpath expr="//header//a[@class='navbar-brand']" position="replace">
<a href="/" class="navbar-brand logo">
<img src="/logo.png" t-att-alt="'Logo of %s' % res_company.name" t-att-title="res_company.name"/>
</a>
</xpath>
</data>
no configuration or operation was made before
to resolve this issue i tried the following:
- update the module by command line - d databasename -u website
- update the module by command line - d databasename -u all
- comment the view "Show Logo" and update website module
- comment the view "Show Logo" and update all modules
none of the above procedures worked then i tried this step
- delete view from ir_ui_view table directly from database using name='Show Logo' as a condition then updated the database with view 'Show logo' commented in odoo-server/addons/website/views/website_templates.xml
this procedure worked for me.
Now my question is why this error happened ? and is it correct to modify directly in website module ?