Skip to content

Commit

Permalink
MDL-77375 core_grades: set boundary of the dropdowns in grade setup page
Browse files Browse the repository at this point in the history
  • Loading branch information
rezaies committed Jul 1, 2023
1 parent 91c29c2 commit 848efb3
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
4 changes: 4 additions & 0 deletions grade/lib.php
Expand Up @@ -2663,6 +2663,10 @@ public function get_cell_action_menu(array $element, string $mode, grade_plugin_
$context->divider2 = false;
}

if ($mode == 'setup') {
$context->databoundary = 'window';
}

if (!empty($USER->editing) || isset($context->gradeanalysisurl) || isset($context->gradesonlyurl)
|| isset($context->aggregatesonlyurl) || isset($context->fullmodeurl) || isset($context->reporturl0)
|| isset($context->ascendingfirstnameurl) || isset($context->ascendingurl)
Expand Down
2 changes: 1 addition & 1 deletion grade/templates/category_settings.mustache
Expand Up @@ -15,7 +15,7 @@
along with Moodle. If not, see <http://www.gnu.org/licenses/>.
}}
{{!
@template core_grades/cellmenu
@template core_grades/category_settings
This template renders action menu for a given cell.
Example context (json):
Expand Down
1 change: 1 addition & 0 deletions grade/templates/cellmenu.mustache
Expand Up @@ -42,6 +42,7 @@
<div class="dropdown">
<button class="btn btn-link btn-icon icon-size-3 cellmenubtn"
type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"
{{#databoundary}}data-boundary="{{databoundary}}"{{/databoundary}}
{{#datatype}}data-type="{{datatype}}"{{/datatype}}
{{#dataid}}data-id="{{dataid}}"{{/dataid}}>
<i class="icon fa fa-ellipsis-h fa-fw m-0" title="{{#str}} cellactions, gradereport_grader {{/str}}" aria-hidden="true"></i>
Expand Down
2 changes: 1 addition & 1 deletion grade/templates/edit_tree.mustache
Expand Up @@ -42,7 +42,7 @@
{{/notification}}
<div class="gradetree-wrapper d-none">
<form id="gradetreeform" method="post" action="{{actionurl}}" >
<div>
<div class="position-relative">
<input type="hidden" name="sesskey" value="{{sesskey}}">
{{{table}}}
{{{stickyfooter}}}
Expand Down

0 comments on commit 848efb3

Please sign in to comment.