With 'target': 'new', res_id is not used

Bug #347925 reported by Xavier Fernandez http://www.smile.fr
2
Affects Status Importance Assigned to Milestone
Odoo GTK Client (MOVED TO GITHUB)
Fix Released
Undecided
Unassigned

Bug Description

When returning a dictionnary to open a new form like that:

return {
                    'view_type': 'form',
                    "view_mode": 'form',
                    'res_model': model,
                    'type': 'ir.actions.act_window',
                    'target':'new',
                    'res_id': context.get('sol_id', False),
                    'context': context,
              }

the res_id is not used in the case of 'target':'new' and the client opens an empty new form.

See the attachment to see the problem and an easy fix.

Revision history for this message
Xavier Fernandez http://www.smile.fr (xav-fernandez) wrote :
Revision history for this message
Xavier Fernandez http://www.smile.fr (xav-fernandez) wrote :

Err patch is bugged :o
See new one.

Revision history for this message
Husen Daudi (husendaudi) wrote :

Thanks for the patch Xavier,
Applied on trunk client.

Changed in openobject-client:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.