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

I have a problem that cannot extend the template website.contactus. It throws error

ValueError: Element '<xpath expr="//div[@name='mail_button']">' cannot be located in parent view

The view is in the table ir_ui_view and it has a div called mail_button. I've tried to extend it like it's extended by the website_crm addon. But the wierd thing is that there is no template with the id contactus in the website addons folder.
The confusing thin is that this worked, bud then I added something to my custom template and upgraded my custom module and it stopped working. I remember that I could there was an option to show this template in the website Customization menu but when you clicked on it the option vanished. I suspect that this is the problem.

How can I get the contactus page back? Or how do I fix the error? 




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

Figured it out. Because there was no xml file with the template I thought it has to be generated. In debug mode I had to go to User Interface -> Views. Find the QWeb view and remove all Inherited views. After that I went on the website and used "/page/contactus" to access the base template or to generate it a new. After that I could extend it again with the custom module.  

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
5
فبراير 24
24043
0
يوليو 18
2601
2
يوليو 18
3010
2
نوفمبر 17
4500
3
مايو 23
15565