MDL-72413 forum: Use the common module for setting the header

This commit is contained in:
Peter Dias
2021-12-13 09:49:34 +08:00
parent 93782ecdb9
commit ab40bc5962
7 changed files with 22 additions and 25 deletions
+4 -4
View File
@@ -43,7 +43,10 @@ $PAGE->set_title($course->shortname.': '.$folder->name);
$PAGE->set_heading($course->fullname);
$PAGE->set_activity_record($folder);
$PAGE->set_secondary_active_tab('modulepage');
$PAGE->activityheader->set_attrs([
'hidecompletion' => true,
'description' => ''
]);
$data = new stdClass();
$data->id = $cm->id;
$maxbytes = get_user_max_upload_file_size($context, $CFG->maxbytes);
@@ -79,9 +82,6 @@ if ($mform->is_cancelled()) {
}
echo $OUTPUT->header();
if (!$PAGE->has_secondary_navigation()) {
echo $OUTPUT->heading(format_string($folder->name));
}
echo $OUTPUT->box_start('generalbox foldertree');
$mform->display();
echo $OUTPUT->box_end();