Skip to content

Commit

Permalink
SAK-49773 Lessons on bulk edit subpage button is missing (sakaiprojec…
Browse files Browse the repository at this point in the history
…t#12570)

Co-authored-by: Sam Ottenhoff <[email protected]>
  • Loading branch information
jonespm and ottenhoff authored May 6, 2024
1 parent cfd02f1 commit 3a01933
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 2 deletions.
12 changes: 12 additions & 0 deletions lessonbuilder/tool/src/webapp/js/show-page.js
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,18 @@ $(document).ready(function () {
bootstrap.Modal.getOrCreateInstance(deleteEl).hide();
});

//Trigger the anchor when these buttons are clicked
document.querySelectorAll('#bulk-edit-pages-button, #reorder-button').forEach(function(button) {
button.addEventListener('click', function(event) {
event.preventDefault();
// Simulate a click on the anchor
let anchor = this.querySelector('a');
if (anchor) {
window.location.href = anchor.getAttribute('href');
}
});
});

/* RU Rubrics ********************************************* */
blankRubricRow = $("#peer-eval-input-cloneable").html();

Expand Down
11 changes: 9 additions & 2 deletions lessonbuilder/tool/src/webapp/templates/ShowPage.html
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,15 @@ <h3 id="toolbar-label" rsf:id="msg=simplepage.toolbar" class="lb-offscreen"></h3
</button>
</li>
<li class="contentButton">
<button class="btn btn-link my-1">
<a href="#" rsf:id="reorder">
<button class="btn btn-link my-1" id="reorder-button">
<a href="#" rsf:id="reorder" tabindex="-1">
<span aria-hidden="true" class="fa-button-text"></span>
</a>
</button>
</li>
<li class="contentButton">
<button class="btn btn-link my-1" id="bulk-edit-pages-button">
<a href="#" rsf:id="bulk-edit-pages" tabindex="-1">
<span aria-hidden="true" class="fa-button-text"></span>
</a>
</button>
Expand Down

0 comments on commit 3a01933

Please sign in to comment.