ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.ilObjLTIConsumerAccess.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
30{
34 public static function _getCommands(): array
35 {
36 return array(
37 array(
38 "permission" => "read",
39 "cmd" => "launch",
40 "lang_var" => "",
41 "default" => true
42 ),
43 array(
44 'permission' => 'write',
45 'cmd' => 'ilLTIConsumerSettingsGUI::showSettings',
46 'lang_var' => 'settings'
47 )
48 );
49 }
50
54 public static function getConditionOperators(): array
55 {
56 return [
58 ];
59 }
60
61 public static function checkCondition(int $a_trigger_obj_id, string $a_operator, string $a_value, int $a_usr_id): bool
62 {
63 if ($a_operator == ilConditionHandler::OPERATOR_PASSED) {
64 return ilLPStatus::_hasUserCompleted($a_trigger_obj_id, $a_usr_id);
65 }
66
67 return false;
68 }
69}
static _hasUserCompleted(int $a_obj_id, int $a_user_id)
Lookup user object completion.
static checkCondition(int $a_trigger_obj_id, string $a_operator, string $a_value, int $a_usr_id)
check condition for a specific user and object
Class ilObjectAccess.
Interface for condition handling.