5 include_once(
"./Services/Object/classes/class.ilObjectAccess.php");
37 array(
"permission" =>
"read",
"cmd" =>
"",
"lang_var" =>
"show",
39 array(
"permission" =>
"write",
"cmd" =>
"editLinks",
"lang_var" =>
"edit_content"),
40 array(
"permission" =>
"write",
"cmd" =>
"settings",
"lang_var" =>
"settings")
53 $t_arr = explode(
"_", $a_target);
55 if ($t_arr[0] !=
"webr" || ((
int) $t_arr[1]) <= 0)
60 if ($ilAccess->checkAccess(
"read",
"", $t_arr[1]) ||
61 $ilAccess->checkAccess(
"visible",
"", $t_arr[1]))
80 public function _checkAccess($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id =
"")
85 if($a_permission ==
'read')
87 if(!self::_getFirstLink($a_obj_id) && !$rbacsystem->checkAccessOfUser($a_user_id,
'write',$a_ref_id))
93 if ($a_cmd ==
"settings")
95 if (self::_checkDirectLink($a_obj_id))
115 if (isset(self::$item[$a_webr_id]))
117 return self::$item[$a_webr_id];
119 $query =
"SELECT * FROM webr_items ".
120 "WHERE webr_id = ". $ilDB->quote($a_webr_id ,
'integer').
' '.
121 "AND active = ".$ilDB->quote(1,
'integer').
' ';
127 $item[
'description'] =
$row->description;
130 $item[
'disable_check'] =
$row->disable_check;
131 $item[
'create_date'] =
$row->create_date;
132 $item[
'last_update'] =
$row->last_update;
151 "SELECT * FROM webr_items WHERE ".
152 $ilDB->in(
"webr_id", $a_obj_ids,
false,
"integer").
153 " AND active = ". $ilDB->quote(1,
'integer'));
154 foreach ($a_obj_ids as $id)
156 self::$item[$id] = array();
161 $item[
'description'] =
$row->description;
164 $item[
'disable_check'] =
$row->disable_check;
165 $item[
'create_date'] =
$row->create_date;
166 $item[
'last_update'] =
$row->last_update;
181 if(isset(self::$single_link[$a_obj_id]))
183 return self::$single_link[$a_obj_id];
185 include_once
'./Modules/WebResource/classes/class.ilLinkResourceItems.php';