mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 12:39:25 +01:00
Make sure we get the right popup if multiple nextmatches use the same popup ID
This commit is contained in:
parent
6774f2e9d4
commit
3164cb6dd0
@ -442,14 +442,14 @@ export function nm_open_popup(_action, _selected)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Find the popup div
|
// Find the popup div
|
||||||
var popup = document.body.querySelector("et2-dialog[id*='" + _action.id + "_popup']") || document.body.querySelector("#" + (uid || "") + "_" + _action.id + "_popup") || document.body.querySelector("[id*='" + _action.id + "_popup']");
|
let nm = _action.data.nextmatch;
|
||||||
|
var popup = (nm?.getInstanceManager().DOMContainer || document.body).querySelector("et2-dialog[id*='" + _action.id + "_popup']") || document.body.querySelector("#" + (uid || "") + "_" + _action.id + "_popup") || document.body.querySelector("[id*='" + _action.id + "_popup']");
|
||||||
if (popup && popup instanceof Et2Dialog)
|
if (popup && popup instanceof Et2Dialog)
|
||||||
{
|
{
|
||||||
popup.show();
|
popup.show();
|
||||||
}
|
}
|
||||||
else if (popup)
|
else if (popup)
|
||||||
{
|
{
|
||||||
let nm = _action.data.nextmatch;
|
|
||||||
let dialog = new Et2Dialog(nm?.egw());
|
let dialog = new Et2Dialog(nm?.egw());
|
||||||
dialog.destroyOnClose = false;
|
dialog.destroyOnClose = false;
|
||||||
dialog.id = popup.id;
|
dialog.id = popup.id;
|
||||||
|
Loading…
Reference in New Issue
Block a user