Allow DRH users to access all announcements from course
@@ -1622,8 +1622,11 @@ class AnnouncementManager
$extraGroupCondition = " AND ip.to_group_id = $group_id ";
}
+ $allowDrhAccess = api_get_configuration_value('allow_drh_access_announcement');
+
if (api_is_allowed_to_edit(false, true) ||
- ($allowUserEditSetting && !api_is_anonymous())
+ ($allowUserEditSetting && !api_is_anonymous()) ||
+ ($allowDrhAccess && api_is_drh())
) {
// A.1. you are a course admin with a USER filter
// => see only the messages of this specific user + the messages of the group (s)he is member of.
@@ -1018,6 +1018,9 @@ VALUES (2, 13, 'session_courses_read_only_mode', 'Lock Course In Session', 1, 1,
// Activate the view with ViewerJS for PDF files within the lessons for IPad and IPhone
// $_configuration['allow_pdf_viewerjs_in_lp'] = false;
+// Allow DRH user to access all session course announcements
+// $_configuration['allow_drh_access_announcement'] = false;
// ------ Custom DB changes (keep this at the end)
// Add user activation by confirmation email
// This option prevents the new user to login in the platform if your account is not confirmed via email