3 declare(strict_types=0);
39 ?
int $a_user_id = null
43 if ($a_user_id === null) {
44 $a_user_id = $DIC->user()->getId();
48 if ($a_permission ===
'read_learning_progress') {
49 return $DIC->access()->checkRbacOrPositionPermissionAccess(
55 return $DIC->access()->checkAccessOfUser(
68 bool $a_allow_only_read =
true 81 if ($DIC->access()->checkAccess(
82 'read_learning_progress',
87 $DIC->access()->checkRbacOrPositionPermissionAccess(
97 if (!$DIC->access()->checkAccess(
'read',
'', $a_ref_id)) {
101 if ($DIC->access()->checkAccess(
102 'edit_learning_progress',
113 if (!$olp->isActive()) {
117 if ($a_allow_only_read) {
static _hasLearningProgressLearner()
static checkAccess(int $a_ref_id, bool $a_allow_only_read=true)
check access to learning progress
Learning progress access checks.
static _lookupObjId(int $ref_id)
static _enabledLearningProgress()
const OP_READ_LEARNING_PROGRESS
static checkPermission(string $a_permission, int $a_ref_id, ?int $a_user_id=null)
wrapper for rbac access checks
static getInstance(int $obj_id)