Use the local context when launching a graph_open action

Using the local context allow us to access the context of the field shown by
the graph when the graph shows a One2Many field.

Closes #14341
(grafted from f186b83936dbde32aca06b3a329bf519df2c8232)

--HG--
branch : 6.0
This commit is contained in:
Nicolas Évrard
2025-10-31 18:04:31 +01:00
parent f948c305fb
commit 2dcadb7fff
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -245,7 +245,7 @@
},
action: function(data, element) {
var ids = this.ids[this._action_key(data)];
var ctx = jQuery.extend({}, this.view.screen.group._context);
var ctx = jQuery.extend({}, this.view.screen.group.local_context);
delete ctx.active_ids;
delete ctx.active_id;
Sao.Action.exec_keyword('graph_open', {
@@ -138,7 +138,7 @@ class Graph(Gtk.DrawingArea):
def action_keyword(self, ids):
if not ids:
return
ctx = self.group._context.copy()
ctx = self.group.local_context.copy()
if 'active_ids' in ctx:
del ctx['active_ids']
if 'active_id' in ctx: