[FIX] account: fix breadcrumbs, action panel which is not appearing in duplicating journal entry
Before this commit, when user duplicates the journal entry, the action panel and breadcrumbs are lost due to 'inline' action given in it for opening form view in edit mode directly. After this commit, when user duplicates the journal entry the action panel and breadcrumbs will be appear and also the form view opens directly in the edit mode. task-1999208 closes odoo/odoo#34127 Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
This commit is contained in:
@@ -446,8 +446,8 @@ class AccountMove(models.Model):
|
||||
def action_duplicate(self):
|
||||
self.ensure_one()
|
||||
action = self.env.ref('account.action_move_journal_line').read()[0]
|
||||
action['target'] = 'inline'
|
||||
action['context'] = dict(self.env.context)
|
||||
action['context']['form_view_initial_mode'] = 'edit'
|
||||
action['context']['view_no_maturity'] = False
|
||||
action['views'] = [(self.env.ref('account.view_move_form').id, 'form')]
|
||||
action['res_id'] = self.copy().id
|
||||
|
||||
Reference in New Issue
Block a user