Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
4 ตอบกลับ
17296 มุมมอง

We have linked odoo to some internal systems.  We have setup some "popup" panels in our system, to show an iframe view of odoo entities, allowing quick and easy editing of the data.  A typical URL for these popups is http://localhost:8069/web?#id=6103&view_type=form&model=sites.site&menu_id=167&action=227.

Is it possible to "hide" the menu in odoo, simply by using a URL parameter or other technique?  Similar to the google maps URL parameter "embed=true"?

This would enable our popups to appear more seamless.

อวตาร
ละทิ้ง

Use target=fullscreen on the action that launches your view

คำตอบที่ดีที่สุด

Set the style of the iframe to hide the top X pixels like this:

position: relative; top: -100px;
อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi Paul,

Yes, you can hide the menu in Odoo by modifying the URL to include the parameter &menu_id=false. For example:

http://localhost:8069/web?#id=6103&view_type=form&model=sites.site&menu_id=false&action=227.

This will hide the menu and create a more seamless popup experience. Keep in mind that Odoo’s interface may vary slightly depending on the version you're using, so it's a good idea to test this in your environment.

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

You have to do this with a work around you can choose from what colleagues suggested above or Kinda Like :

- Via css : you can make the iframe Position - 100PX  so the menu would be hidden , or place some box/block to be fixed with the same dimensions as the menu  of Odoo

i dont recommend you to edit this in odoo itself cuz this will Hide  the menu from the entire System , and i recommend you to control this via your iframe except you are aware of doing this .

Regards ,

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi,

No native function to do it ! 

But you simply do it with a1 inherited view...

Inherit the view web.webclient_bootstrap and add a if to check if get param "embed" is present...


<xpath expr="//nav[@id='oe_main_menu_navbar']" position="attributes">
       <attribute name="class"></attribute>
       <attribute name="t-att-class">"navbar navbar-inverse %s" % (request.params.get('embed') and "hidden")</attribute>
</xpath>


อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
1
ส.ค. 25
4071
1
ก.พ. 25
5407
How do I integrate Odoo to Salesforce? แก้ไขแล้ว
3
ส.ค. 19
8746
2
ก.ค. 25
1785
2
ก.พ. 25
3896