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

Hello, I am having a hard time closing the open dialogs when I click a button to go to another form.  the dialogs open when I click on a one2many line item, then that dialog has a button which opens a form.  the problem is when i click the button to open the form, the current dialogs that are open don't close.  Can someone tell me how to close an open dialog on a button click?

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

Eric,

On the button click, write a method which returns:

return {'type': 'ir.actions.act_window_close'}

Thanks.

อวตาร
ละทิ้ง

Hi Serpent Consulting Services Pvt. Ltd, I trying to print a report from the button and close that wizard. Any idea to achieve this.

So I have to return this to have the pdf : return self.env['report'].get_action(record_to_print, 'account.report_invoice') , but how do I close the wizard after this?

Hi Thanks for your help. It works for me.

Related Posts ตอบกลับ มุมมอง กิจกรรม
3
ก.ย. 23
3528
2
ก.ย. 23
4700
2
ธ.ค. 21
12609
1
พ.ย. 19
5673
Open the form view into a Wizard แก้ไขแล้ว
2
ธ.ค. 16
14787