Commit 757ba5e6 authored by Robert Lyon's avatar Robert Lyon

Bug 1817326: Modal in a Modal popup problem for editcomposite

When closing the inner modal it removes a class from the <body> tag
causing the scrolling to break

behatnotneeded

Change-Id: Ic7d6678a6d69d57343678f1ca57e8fa2e00861e2
Signed-off-by: Robert Lyon's avatarRobert Lyon <robertl@catalyst.net.nz>
(cherry picked from commit 5bff19e5)
parent b50c1565
......@@ -108,6 +108,14 @@ function editcomposite_callback(form, data) {
formError(form, data);
}
};
$(function($) {
$('#page-modal').on('hidden.bs.modal', function (e) {
// check if the upload file modal is still visible and if so put the body class back to allow scrolling
if ($('#editcomposite_filebrowser_upload_browse').hasClass('show')) {
$('body').addClass('modal-open');
}
});
});
EOF;
$smarty = smarty(array('js/switchbox.js'));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment