-
Improvement
-
Resolution: Won't Do
-
Minor
-
None
-
2.5.3, 2.8.7, 2.9.1, 3.0.4
-
MOODLE_25_STABLE, MOODLE_28_STABLE, MOODLE_29_STABLE, MOODLE_30_STABLE
Access to the topic or activity can be restricted based upon user profile field. The language (lang) field is not available. I think this would be a great enhancement to the access restrictions, to be able to restrict access based upon the users' language setting in the user profile field (defaulting to system default language). This would enhance our ability to localize a course to a user, to only display the content that is applicable to the users' language
To accomplish this I have added 2 lines of code in 2 files.
1) /lib/conditionlib.php on line 641: 'lang' => get_user_field_name('lang'),
2) /lib/moodlelib.php on line 3730: case 'language' : return get_string('lang');
Thanks!
There is already an implementation of this in plugin database: https://moodle.org/plugins/view/availability_language
- has been marked as being related by
-
MDL-50951 POLICY: Accepting new plugins into Moodle and removing unpopular ones
-
- Closed
-
- is blocked by
-
MDL-44070 Conditional availability: Enhancements including OR conditions, plugins
-
- Closed
-
- is duplicated by
-
MDL-39823 Allow resources/activities to be contionally visible depending on language
-
- Closed
-