From e924e4b2d32d92f738562215d4f356fe9fc0d48d Mon Sep 17 00:00:00 2001 From: Ruben Pingol <128448242+rubenpingol-xibo@users.noreply.github.com> Date: Tue, 16 Jan 2024 17:09:16 +0800 Subject: [PATCH] Layout Name Edit: Fix multiple modal opening (#2309) relates to xibosignage/xibo#3278 --- ui/src/core/xibo-cms.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/ui/src/core/xibo-cms.js b/ui/src/core/xibo-cms.js index 933af9e140..2fbe7a7c6a 100644 --- a/ui/src/core/xibo-cms.js +++ b/ui/src/core/xibo-cms.js @@ -1940,9 +1940,6 @@ function XiboFormRender(sourceObj, data = null) { return false; } - // Currently only support one of these at once. - bootbox.hideAll(); - lastForm = formUrl; // Call with AJAX @@ -2009,6 +2006,12 @@ function XiboFormRender(sourceObj, data = null) { if (sourceObj && typeof sourceObj === 'object') { size = sourceObj.data().modalSize || 'large'; } + + // Currently only support one of these at once. + // We have to move this here before calling bootbox.dialog + // to avoid multiple modal being opened + bootbox.hideAll(); + var dialog = bootbox.dialog({ message: response.html, title: dialogTitle,