MDL-44070 Conditional availability enhancements (6): core changes
Changes core code to use new API instead of the old one when checking user access to activities and sections. Includes changes to other libraries that are necessary after adding the availability system and removing old conditional tables etc.
This commit is contained in:
@@ -176,7 +176,7 @@ abstract class testing_module_generator extends component_generator_base {
|
||||
$easymergefields = array('section', 'added', 'score', 'indent',
|
||||
'visible', 'visibleold', 'groupmode', 'groupingid', 'groupmembersonly',
|
||||
'completion', 'completiongradeitemnumber', 'completionview', 'completionexpected',
|
||||
'availablefrom', 'availableuntil', 'showavailability', 'showdescription');
|
||||
'availability', 'showdescription');
|
||||
foreach ($easymergefields as $key) {
|
||||
if (isset($options[$key])) {
|
||||
$moduleinfo->$key = $options[$key];
|
||||
@@ -191,9 +191,7 @@ abstract class testing_module_generator extends component_generator_base {
|
||||
'groupmode' => 0,
|
||||
'groupingid' => 0,
|
||||
'groupmembersonly' => 0,
|
||||
'showavailability' => 0,
|
||||
'availablefrom' => 0,
|
||||
'availableuntil' => 0,
|
||||
'availability' => null,
|
||||
'completion' => 0,
|
||||
'completionview' => 0,
|
||||
'completionexpected' => 0,
|
||||
|
||||
Reference in New Issue
Block a user