From 9872f0a8b847098f861eb6d24fd7a52a8dd5f3de Mon Sep 17 00:00:00 2001 From: Tim Hunt Date: Wed, 13 May 2015 09:58:13 +0100 Subject: [PATCH] MDL-50217 questions: sensible default order for add new qtype This default will only affect new installs. --- lib/db/install.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/db/install.php b/lib/db/install.php index d3ca874c629..f8dbdce278a 100644 --- a/lib/db/install.php +++ b/lib/db/install.php @@ -306,4 +306,12 @@ function xmldb_main_install() { $DB->insert_record('my_pages', $mypage); $mypage->private = 1; $DB->insert_record('my_pages', $mypage); + + // Set a sensible default sort order for the most-used question types. + set_config('multichoice_sortorder', 1, 'question'); + set_config('truefalse_sortorder', 2, 'question'); + set_config('match_sortorder', 3, 'question'); + set_config('shortanswer_sortorder', 4, 'question'); + set_config('numerical_sortorder', 5, 'question'); + set_config('essay_sortorder', 6, 'question'); } -- 2.43.0