Skip to Content
Menú
This question has been flagged
1 Respondre
3421 Vistes

Hello everyone,

I'm trying to be used on Odoo website theming, so i'm following up the Theme Tutorial (https://www.odoo.com/documentation/13.0/howtos/themes.html#structure-of-an-odoo-page

I followed the tutorial and created the directory structure :

theme_name/

|--__init__.py

|--__manifest__.py

|--|views

|--|static


I'm stuck in the "Create a specific page layout" section.
I created the pages.xml the the following code :

<?xml version="1.0" encoding="utf-8" ?>
<odoo>
    <template id="services_page_template" >
        <t t-call="website.layout">
            <div id="wrap">
                <div id="container">
                    <h1>Our Services</h1>
                    <ul class="services">
                        <li>Cloud Hosting</li>
                        <li>Support</li>
                        <li>Unlimited space</li>
                    </ul>
                    <div class="oe_structure" />
                </div>
            </div> 
        </t>
    </template>
    <record id="services_page" model="website.page">
        <field name="name">Services page</field>
        <field name="website_published">True</field>
        <field name="url">/services</field>
        <field name="view_id" ref="services_page_template" />
    </record>
    <record id="services_page_link" model="website.menu">
        <field name="name">Services</field>
        <field name="page_id" ref="services_page"/>
        <field name="parent_id" ref="website.main_menu" />
        <field name="sequence" type="int">99</field>
    </record>        
</odoo>


The __manifest__.py file looks like :

{
  'name':'Theme Canvas',
  'description': 'Canvas theme template.',
  'category': 'Theme/Services',
  'version':'1.0',
  'author':'Daniel Perrot',
  'depends': ['website', 'website_theme_install'],
  'data': [ 
    'views/layout.xml',
    'views/pages.xml',
    'views/assets.xml',
    'views/snippets.xml',
  ],

}


I pushed and updated the content on odoo.sh (the build is OK)

I update the theme.

When i go on the website (https://erpserv-theme-canvas-1116835.dev.odoo.com/) i can see the main layout customisation (blue welcome block).

But when a clic on the menu button 'services' (which is the custom page) the page is not displayed. The main odoo navbar is not displayed neither...


I checked and checked again.. but i can't understand why...

If somebody can help...?


Thx

Daniel


Avatar
Descartar
Best Answer

Hi, You can check this: 

https://youtu.be/zqFuvqnC3zs

Hope it helps

Avatar
Descartar
Related Posts Respostes Vistes Activitat
0
de set. 20
7472
1
d’abr. 20
6585
0
de jul. 24
1397
4
de maig 24
12641
1
d’abr. 24
3276