Skip to content

Commit 1326e31

Browse files
authored
rebased (#516)
Signed-off-by: rezeau <[email protected]>
1 parent 46bd6b3 commit 1326e31

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

lib.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,13 @@ function questionnaire_get_coursemodule_info($coursemodule) {
262262

263263
$info = new cached_cm_info();
264264
$info->customdata = (object)[];
265+
266+
if ($coursemodule->showdescription) {
267+
// Convert intro to html. Do not filter cached version, filters run at display time.
268+
// Based on the function quiz_get_coursemodule_info() in the quiz module.
269+
$info->content = format_module_intro('questionnaire', $questionnaire, $coursemodule->id, false);
270+
}
271+
265272
// Populate the custom completion rules as key => value pairs, but only if the completion mode is 'automatic'.
266273
if ($coursemodule->completion == COMPLETION_TRACKING_AUTOMATIC) {
267274
$info->customdata->customcompletionrules['completionsubmit'] = $questionnaire->completionsubmit;

0 commit comments

Comments
 (0)