19 include_once
"./Modules/Test/classes/inc.AssessmentConstants.php";
47 array(
"permission" =>
"write",
"cmd" =>
"questions",
"lang_var" =>
"tst_edit_questions"),
48 array(
"permission" =>
"write",
"cmd" =>
"ilObjQuestionPoolSettingsGeneralGUI::showForm",
"lang_var" =>
"settings"),
49 #array(
"permission" =>
"write",
"cmd" =>
"questions",
"lang_var" =>
"edit",
50 #
"default" =>
false),
51 array(
"permission" =>
"read",
"cmd" =>
"questions",
"lang_var" =>
"edit",
58 public function _checkAccess(
string $cmd,
string $permission,
int $ref_id,
int $obj_id, ?
int $user_id = null): bool
63 $rbacsystem = $DIC[
'rbacsystem'];
64 $ilAccess = $DIC[
'ilAccess'];
66 if (is_null($user_id)) {
70 if ($rbacsystem->checkAccessOfUser($user_id,
'write', $ref_id)) {
74 switch ($permission) {
77 if (!self::isOnline($obj_id)) {
93 public static function isOnline($a_obj_id): bool
99 SELECT COUNT(id_questionpool) cnt 100 FROM qpl_questionpool 108 return $row[
'cnt'] > 0;
_checkAccess(string $cmd, string $permission, int $ref_id, int $obj_id, ?int $user_id=null)
const IL_NO_OBJECT_ACCESS
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static _getCommands()
get commands
static isOnline($a_obj_id)
returns the objects's ONline status