Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
3040 Lượt xem

Hello, I'm trying to make a new theme for odoo-8 website.. By following these steps in \odoo-theme-tutorial . when went through step of Extend the default header I didn't get the expected output. All I get is a page og text without applying neither the CSS effect nor the JS. I don't know what am I missing.. any help will be appreciated.Here's my code:

in openerp file:

{

# Theme information

'name': "theme_businesscasual",

'description': """

""",

'category': 'Theme',

'version': '1.0',

'depends': ['website', 'website_less'],

# templates

'data': [

'views/layout.xml',

],

'application': True

}

in layout.xml file:

<?xml version="1.0" encoding="utf-8" ?>

<openerp>

<data>

<!-- Customize header -->

<template id="custom_header" inherit_id="website.layout" name="Custom Header">

<!-- Assign an id -->

<xpath expr="//div[@id='wrapwrap']/header" position="attributes">

<attribute name="id">my_header</attribute>

</xpath>

<!-- Add an element after the top menu -->

<xpath expr="//div[@id='wrapwrap']/header/div" position="after">

<div class="container">

<div class="alert alert-info mt16" role="alert">

<strong>Welcome</strong> to our website!

</div>

</div>

</xpath>

</template>

</data>

</openerp>

Here's a screenshot of what I get:


screenshot in this link : https://drive.google.com/open?id=0B8l_J46zjX-1VEpTN3lCRXRsbkk

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Normally that is related to non installed less dependencies

check that you have installed:

via apt-get: node-js, npm

via npm: less, less-plugin-clean-css

and make sure that the command node it's refering to the node-js installed

After you have set those steps done you should be able to see the website normally

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
0
thg 6 16
3567
0
thg 4 23
3003
1
thg 3 21
11184
1
thg 2 17
5707
1
thg 1 23
2549