Commit aa717c58 authored by Astor Bizard's avatar Astor Bizard 🐕
Browse files

Fixed order of based on selection.

parent 7f8f444c
......@@ -26,6 +26,7 @@
require_once(dirname(__FILE__).'/../../../config.php');
require_once(dirname(__FILE__).'/../locallib.php');
require_once(dirname(__FILE__).'/../vpl.class.php');
global $CFG;
require_once($CFG->libdir.'/formslib.php');
class mod_vpl_executionoptions_form extends moodleform {
......@@ -39,6 +40,7 @@ class mod_vpl_executionoptions_form extends moodleform {
if ($data === false ) {
return '';
}
$matches = [];
$result = preg_match('/@vpl_script_description (.*)$/im', $data, $matches);
if ( $result ) {
return ': ' . $matches[1];
......@@ -97,6 +99,7 @@ class mod_vpl_executionoptions_form extends moodleform {
}
}
}
asort($basedonlist[$courseid]);
}
foreach ($basedonlist as $courseid => $vpls) {
......@@ -124,6 +127,7 @@ class mod_vpl_executionoptions_form extends moodleform {
$basedonlist[$shared][$sharedvpl->instance] = $vpl->get_printable_name();
}
}
asort($basedonlist[$shared]);
}
if ($instance->basedon) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment