48 array(
"permission" =>
"read",
"cmd" =>
"infoScreen",
"lang_var" =>
"info_short",
"default" =>
true),
49 array(
"permission" =>
"read",
"cmd" =>
"register",
"lang_var" =>
"join_session"),
50 array(
"permission" =>
"read",
"cmd" =>
"unregister",
"lang_var" =>
"event_unregister"),
51 array(
"permission" =>
"write",
"cmd" =>
"edit",
"lang_var" =>
"edit"),
52 array(
'permission' =>
'write',
'cmd' =>
'members',
'lang_var' =>
'event_edit_members')
70 public function _checkAccess($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id =
"")
72 global $ilUser,
$lng, $rbacsystem, $ilAccess;
74 $a_user_id = $a_user_id ? $a_user_id : $ilUser->getId();
78 if(self::_lookupRegistration($a_obj_id))
85 if(self::_lookupRegistration($a_obj_id))
102 $t_arr = explode(
"_", $a_target);
104 if ($t_arr[0] !=
"sess" || ((
int) $t_arr[1]) <= 0)
109 if($ilAccess->checkAccess(
"read",
"", $t_arr[1]))
126 if(!is_null(self::$registrations))
128 return self::$registrations[$a_obj_id];
133 $query =
"SELECT registration,obj_id FROM event ";
137 self::$registrations[
$row->obj_id] = (bool)
$row->registration;
139 return self::$registrations[$a_obj_id];
153 if(isset(self::$registered[$a_usr_id]))
155 return (
bool) self::$registered[$a_usr_id][$a_obj_id];
158 global
$ilDB,$ilUser;
160 $query =
"SELECT event_id, registered FROM event_participants WHERE usr_id = ".$ilDB->quote($ilUser->getId(),
'integer');
162 self::$registered[$a_usr_id] = array();
165 self::$registered[$a_usr_id][
$row->event_id] = (bool)
$row->registered;
167 return (
bool) self::$registered[$a_usr_id][$a_obj_id];