Commit 9bd277e5 authored by Robert Lyon's avatar Robert Lyon

Bug 1817326: Modal in a Modal popup problem

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

behatnotneeded

Change-Id: I9d132a91cd48500276951c24c0987b418daacb6e
Signed-off-by: Robert Lyon's avatarRobert Lyon <robertl@catalyst.net.nz>
parent 1b05a031
......@@ -125,6 +125,15 @@ $javascript = <<<EOF
function editgoalsandskills_callback(form, data) {
editgoalsandskills_filebrowser.callback(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 ($('#editgoalsandskills_filebrowser_upload_browse').hasClass('show')) {
$('body').addClass('modal-open');
}
});
});
EOF;
$smarty = smarty(array(), array(), array(), array(
......
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