콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
6 답글
14033 화면

I want to hide the Home button from the navigation bar of Odoo12 website.
Not sure how to do that with code, can anyone help me out in this?
Thanks

아바타
취소
작성자

Hi Mitul Shingala,

I am new to this so please can you help me out by the code.

I am updating my answer. please add the below code into your code. using that field you can achieve your goal.

작성자

Hi Bouabaker Abdallah,

Its not working!

베스트 답변

Try this in your XML file 


<?xml version="1.0" encoding="utf-8"?>
<odoo>
 <template id="my_header" inherit_id="website.layout" name="my_header">
        <xpath expr="//header" position="replace">
                    <header>
add your specific menu here
                   </header>
        </xpath>
</template>
 </odoo>

아바타
취소
베스트 답변

Hello

you can do with add 'active' field into the object 'website.menu'

or using the 'is_visible' field available into the   website.menu object.

class website_menu(models.Model):

    _inherit = 'website.menu'

    active = fields.Boolean(string="Active", default=True) # if this field is mark as checked then it will visible into the menu

# inherit the xml view and add the field into the xml view also. so into the form view you can see the field and then try. 


아바타
취소
관련 게시물 답글 화면 활동
0
1월 20
2903
3
3월 24
7164
1
5월 22
3013
0
12월 19
2722
1
10월 19
5798