6 include_once(
"./Services/Object/classes/class.ilObjectAccess.php");
47 $this->
user = $DIC->user();
48 $this->lng = $DIC->language();
49 $this->rbacsystem = $DIC->rbac()->system();
50 $this->access = $DIC->access();
66 public function _checkAccess($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id =
"")
73 if ($a_user_id ==
"") {
77 switch ($a_permission) {
80 && !
$rbacsystem->checkAccessOfUser($a_user_id,
'write', $a_ref_id)) {
88 (!
$rbacsystem->checkAccessOfUser($a_user_id,
'write', $a_ref_id))) {
114 array(
"permission" =>
"read",
"cmd" =>
"view",
"lang_var" =>
"show",
116 array(
"permission" =>
"write",
"cmd" =>
"edit",
"lang_var" =>
"edit_content"),
117 array(
"permission" =>
"edit_content",
"cmd" =>
"edit",
"lang_var" =>
"edit_content"),
118 array(
"permission" =>
"write",
"cmd" =>
"properties",
"lang_var" =>
"settings")
135 $ilDB = $DIC->database();
137 $q =
"SELECT * FROM glossary WHERE id = " .
138 $ilDB->quote($a_id,
"integer");
152 $ilAccess = $DIC->access();
154 $t_arr = explode(
"_", $a_target);
156 if (($t_arr[0] !=
"glo" && $t_arr[0] !=
"git") || ((
int) $t_arr[1]) <= 0) {
160 if ($t_arr[0] ==
"glo") {
161 if ($ilAccess->checkAccess(
"read",
"", $t_arr[1]) ||
162 $ilAccess->checkAccess(
"visible",
"", $t_arr[1])) {
167 if ($t_arr[0] ==
"git") {
169 $ref_ids =
array($t_arr[2]);
172 require_once(
"./Modules/Glossary/classes/class.ilGlossaryTerm.php");
177 foreach ($ref_ids as $ref_id) {
179 if ($ilAccess->checkAccess(
"read",
"", $ref_id)) {
_checkAccess($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id="")
checks wether a user may invoke a command or not (this method is called by ilAccessHandler::checkAcce...
const IL_NO_OBJECT_ACCESS
static _lookupOnline($a_id)
check wether learning module is online
static _getCommands()
get commands
static _getAllReferences($a_id)
get all reference ids of object
static _checkGoto($a_target)
check whether goto script will succeed
Class ilObjGlossaryAccess.
Create styles array
The data for the language used.
static _lookGlossaryID($term_id)
get glossary id form term id
static yn2tf($a_yn)
convert "y"/"n" to true/false
__construct()
Constructor.