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

How to hide a tab(s) or a sub-tab(s) in CONTACT - with STUDIO ? V13
Ảnh đại diện
Huỷ bỏ
Tác giả Câu trả lời hay nhất

 Context:

 

Your client doesn’t need to see or use specific tab(s) in Contact and want to remove their visibility for all the users of the DB, because he will never impact the fields contain in these tab(s)/sub-tab(s).

 

Process:

 

1. You need to have STUDIO and activate the developer mode for realizing this process

2. Tab or sub-tab

a) Either you created a new tab with Studio and this new tab will appear in the XML view “Odoo Studio:res.partner.form.customization”

b) Either you want to hide an existing tab, and in this case in order to find easier the mention of this tab in the XML view, you should change the name of the tab in order for it to appear in the modification done by STUDIO “Odoo Studio:res.partner.form.customization”

3. Once Studio activated, click on “View” (upper left of the screen) for opening the xml view of the page.

4. In the xml view, select [Odoo Studio: res.partner.form.customization] for finding back mention of the tab/sub-tab to hide

5. Once the tab/sub-tab found in the xml view, add this code next to them [1] and after the next “>”.


  

 

 You can also add a condition for hiding the tab/sub-tab only under certain condition (ex: inf the contact is a company, hide the tab/sub-tab). In this case, you should use this code [attrs="{"invisible": [["is_company","!=",False]]}">>] right after the mention of the tab/sub-tab and before the next “>”.

6. Once the code added, you can save your modifications, close STUDIO and check the results. :) 

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 2 23
3213
1
thg 9 21
3661
2
thg 6 25
3097
1
thg 2 24
3296
1
thg 11 21
3061