Browse Source

Cog menu on teacher page under Boost based themes

MOODLE_35_STABLE
Neill Magill 7 years ago
committed by Dan Marsden
parent
commit
35c88f84ea
  1. 1
      export.php
  2. 1
      manage.php
  3. 1
      preferences.php
  4. 1
      report.php
  5. 1
      sessions.php
  6. 1
      tempusers.php
  7. 14
      tests/behat/report.feature

1
export.php

@ -44,6 +44,7 @@ $att = new mod_attendance_structure($att, $cm, $course, $context);
$PAGE->set_url($att->url_export()); $PAGE->set_url($att->url_export());
$PAGE->set_title($course->shortname. ": ".$att->name); $PAGE->set_title($course->shortname. ": ".$att->name);
$PAGE->set_heading($course->fullname); $PAGE->set_heading($course->fullname);
$PAGE->force_settings_menu(true);
$PAGE->set_cacheable(true); $PAGE->set_cacheable(true);
$PAGE->navbar->add(get_string('export', 'attendance')); $PAGE->navbar->add(get_string('export', 'attendance'));

1
manage.php

@ -75,6 +75,7 @@ $PAGE->set_url($att->url_manage());
$PAGE->set_title($course->shortname. ": ".$att->name); $PAGE->set_title($course->shortname. ": ".$att->name);
$PAGE->set_heading($course->fullname); $PAGE->set_heading($course->fullname);
$PAGE->set_cacheable(true); $PAGE->set_cacheable(true);
$PAGE->force_settings_menu(true);
$PAGE->navbar->add($att->name); $PAGE->navbar->add($att->name);
$output = $PAGE->get_renderer('mod_attendance'); $output = $PAGE->get_renderer('mod_attendance');

1
preferences.php

@ -52,6 +52,7 @@ $att = new mod_attendance_structure($att, $cm, $course, $context, $pageparams);
$PAGE->set_url($att->url_preferences()); $PAGE->set_url($att->url_preferences());
$PAGE->set_title($course->shortname. ": ".$att->name.' - '.get_string('settings', 'attendance')); $PAGE->set_title($course->shortname. ": ".$att->name.' - '.get_string('settings', 'attendance'));
$PAGE->set_heading($course->fullname); $PAGE->set_heading($course->fullname);
$PAGE->force_settings_menu(true);
$PAGE->set_cacheable(true); $PAGE->set_cacheable(true);
$PAGE->navbar->add(get_string('settings', 'attendance')); $PAGE->navbar->add(get_string('settings', 'attendance'));

1
report.php

@ -56,6 +56,7 @@ $PAGE->set_url($att->url_report());
$PAGE->set_pagelayout('report'); $PAGE->set_pagelayout('report');
$PAGE->set_title($course->shortname. ": ".$att->name.' - '.get_string('report', 'attendance')); $PAGE->set_title($course->shortname. ": ".$att->name.' - '.get_string('report', 'attendance'));
$PAGE->set_heading($course->fullname); $PAGE->set_heading($course->fullname);
$PAGE->force_settings_menu(true);
$PAGE->set_cacheable(true); $PAGE->set_cacheable(true);
$PAGE->navbar->add(get_string('report', 'attendance')); $PAGE->navbar->add(get_string('report', 'attendance'));

1
sessions.php

@ -58,6 +58,7 @@ $att = new mod_attendance_structure($att, $cm, $course, $context, $pageparams);
$PAGE->set_url($att->url_sessions(array('action' => $pageparams->action))); $PAGE->set_url($att->url_sessions(array('action' => $pageparams->action)));
$PAGE->set_title($course->shortname. ": ".$att->name); $PAGE->set_title($course->shortname. ": ".$att->name);
$PAGE->set_heading($course->fullname); $PAGE->set_heading($course->fullname);
$PAGE->force_settings_menu(true);
$PAGE->set_cacheable(true); $PAGE->set_cacheable(true);
$PAGE->navbar->add($att->name); $PAGE->navbar->add($att->name);

1
tempusers.php

@ -42,6 +42,7 @@ require_capability('mod/attendance:managetemporaryusers', $context);
$PAGE->set_title($course->shortname.": ".$att->name.' - '.get_string('tempusers', 'attendance')); $PAGE->set_title($course->shortname.": ".$att->name.' - '.get_string('tempusers', 'attendance'));
$PAGE->set_heading($course->fullname); $PAGE->set_heading($course->fullname);
$PAGE->force_settings_menu(true);
$PAGE->set_cacheable(true); $PAGE->set_cacheable(true);
$PAGE->navbar->add(get_string('tempusers', 'attendance')); $PAGE->navbar->add(get_string('tempusers', 'attendance'));

14
tests/behat/report.feature

@ -22,8 +22,6 @@ Feature: Visiting reports
And I add a "Attendance" to section "1" and I fill the form with: And I add a "Attendance" to section "1" and I fill the form with:
| Name | Attendance | | Name | Attendance |
And I follow "Attendance" And I follow "Attendance"
And I follow "Add a block"
And I follow "Administration"
And I follow "Add session" And I follow "Add session"
And I set the following fields to these values: And I set the following fields to these values:
| id_sestime_starthour | 01 | | id_sestime_starthour | 01 |
@ -41,7 +39,7 @@ Feature: Visiting reports
Given I log in as "teacher1" Given I log in as "teacher1"
And I am on "Course 1" course homepage And I am on "Course 1" course homepage
And I follow "Attendance" And I follow "Attendance"
And I follow "Edit settings" And I navigate to "Edit settings" in current page administration
Then I set the following fields to these values: Then I set the following fields to these values:
| id_grade_modgrade_type | Point | | id_grade_modgrade_type | Point |
| id_grade_modgrade_point | 50 | | id_grade_modgrade_point | 50 |
@ -75,7 +73,7 @@ Feature: Visiting reports
Given I log in as "teacher1" Given I log in as "teacher1"
And I am on "Course 1" course homepage And I am on "Course 1" course homepage
And I follow "Attendance" And I follow "Attendance"
And I follow "Edit settings" And I navigate to "Edit settings" in current page administration
Then I set the following fields to these values: Then I set the following fields to these values:
| id_grade_modgrade_type | Point | | id_grade_modgrade_type | Point |
| id_grade_modgrade_point | 50 | | id_grade_modgrade_point | 50 |
@ -88,7 +86,7 @@ Feature: Visiting reports
And I press "Save attendance" And I press "Save attendance"
When I follow "Attendance" When I follow "Attendance"
And I follow "Edit settings" And I navigate to "Edit settings" in current page administration
Then I set the following fields to these values: Then I set the following fields to these values:
| id_grade_modgrade_type | Point | | id_grade_modgrade_type | Point |
| id_grade_modgrade_point | 70 | | id_grade_modgrade_point | 70 |
@ -114,7 +112,7 @@ Feature: Visiting reports
When I log in as "teacher1" When I log in as "teacher1"
And I am on "Course 1" course homepage And I am on "Course 1" course homepage
And I follow "Attendance" And I follow "Attendance"
And I follow "Edit settings" And I navigate to "Edit settings" in current page administration
And I set the following fields to these values: And I set the following fields to these values:
| id_grade_modgrade_type | Point | | id_grade_modgrade_type | Point |
| id_grade_modgrade_point | 50 | | id_grade_modgrade_point | 50 |
@ -156,7 +154,7 @@ Feature: Visiting reports
Given I log in as "teacher1" Given I log in as "teacher1"
And I am on "Course 1" course homepage And I am on "Course 1" course homepage
And I follow "Attendance" And I follow "Attendance"
And I follow "Edit settings" And I navigate to "Edit settings" in current page administration
And I set the following fields to these values: And I set the following fields to these values:
| id_grade_modgrade_type | Point | | id_grade_modgrade_type | Point |
| id_grade_modgrade_point | 50 | | id_grade_modgrade_point | 50 |
@ -203,7 +201,7 @@ Feature: Visiting reports
Given I log in as "teacher1" Given I log in as "teacher1"
And I am on "Course 1" course homepage And I am on "Course 1" course homepage
And I follow "Attendance" And I follow "Attendance"
And I follow "Edit settings" And I navigate to "Edit settings" in current page administration
Then I set the following fields to these values: Then I set the following fields to these values:
| id_grade_modgrade_type | Point | | id_grade_modgrade_type | Point |
| id_grade_modgrade_point | 50 | | id_grade_modgrade_point | 50 |

Loading…
Cancel
Save