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

I wanted to inherit the home page to add some information for login user  I followed 

https://www.odoo.com/fr_FR/forum/aide-1/question/odoo-v11-website-how-to-replace-home-page-139437

and 

https://www.youtube.com/watch?v=htVBViZl45Q

it is not working this is my code


from odoo import http
from odoo.http import request
from odoo.addons.website_sale.controllers.main import Website
class Website_inherit(Website):
    @http.route('/', type='http', auth="public", website=True)
    def index(self, **kw):
        res = super(Website_inherit, self).index(**kw)
        print("vlad work")
        
        
        return http.request.render('n_theme.name_app', data)






Ảnh đại diện
Huỷ bỏ

def index(self, data={}, **kw):

pls replace

Tác giả

hi @Usman thank u for replying

it did not work

Bài viết liên quan Trả lời Lượt xem Hoạt động
2
thg 12 21
24209
3
thg 7 21
21097
0
thg 1 21
2089
1
thg 11 20
6452
1
thg 9 20
3220