Class ilContentPageKioskModeView.
More...
|
| buildInitialState (State $empty_state) |
|
| buildControls (State $state, ControlBuilder $builder) |
|
| updateGet (State $state, string $command, int $param=null) |
|
| updatePost (State $state, string $command, array $post) |
|
| render (State $state, Factory $factory, URLBuilder $url_builder, array $post=null) |
|
| __construct (\ilObject $object, \ilCtrl $ctrl, \ilLanguage $lng, \ilAccessHandler $access) |
|
| render (State $state, UI\Factory $factory, URLBuilder $url_builder, array $post=null) |
| Render a state using the ui-factory and URLs from the builder. More...
|
|
◆ buildControls()
◆ buildInitialState()
ilContentPageKioskModeView::buildInitialState |
( |
State |
$empty_state | ) |
|
◆ builtLearningProgressToggleControl()
ilContentPageKioskModeView::builtLearningProgressToggleControl |
( |
ControlBuilder |
$builder | ) |
|
|
protected |
◆ getObjectClass()
ilContentPageKioskModeView::getObjectClass |
( |
| ) |
|
|
protected |
◆ hasPermissionToAccessKioskMode()
ilContentPageKioskModeView::hasPermissionToAccessKioskMode |
( |
| ) |
|
|
protected |
◆ render()
ilContentPageKioskModeView::render |
( |
State |
$state, |
|
|
Factory |
$factory, |
|
|
URLBuilder |
$url_builder, |
|
|
array |
$post = null |
|
) |
| |
Definition at line 173 of file class.ilContentPageKioskModeView.php.
References ilLearningProgress\_tracProgress(), ILIAS\UI\Factory\legacy(), ilContentPagePageCommandForwarder\PRESENTATION_MODE_EMBEDDED_PRESENTATION, renderContentStyle(), and user().
180 $this->
user->getId(),
181 $this->contentPageObject->getId(),
182 $this->contentPageObject->getRefId(),
183 $this->contentPageObject->getType()
188 $forwarder = new \ilContentPagePageCommandForwarder(
193 $this->contentPageObject
197 $this->ctrl->setParameterByClass(\ilContentPagePageGUI::class,
'ref_id', $this->contentPageObject->getRefId());
199 return $factory->
legacy(implode(
'', [
200 $this->uiRenderer->render($this->messages),
201 $forwarder->forward($this->ctrl->getLinkTargetByClass([
202 \ilRepositoryGUI::class, \ilObjContentPageGUI::class, \ilContentPagePageGUI::class
renderContentStyle()
Renders the content style of a ContentPage object into main template.
const PRESENTATION_MODE_EMBEDDED_PRESENTATION
presentation mode for embedded presentation, e.g.
static _tracProgress($a_user_id, $a_obj_id, $a_ref_id, $a_obj_type='')
legacy($content)
description: purpose: > This component is used to wrap an existing ILIAS UI element into a UI compon...
◆ renderContentStyle()
ilContentPageKioskModeView::renderContentStyle |
( |
| ) |
|
|
protected |
◆ setObject()
ilContentPageKioskModeView::setObject |
( |
\ilObject |
$object | ) |
|
|
protected |
Definition at line 59 of file class.ilContentPageKioskModeView.php.
References $DIC, and user().
63 $this->contentPageObject = $object;
65 $this->ctrl = $DIC->ctrl();
66 $this->mainTemplate = $DIC->ui()->mainTemplate();
67 $this->uiFactory = $DIC->ui()->factory();
68 $this->uiRenderer = $DIC->ui()->renderer();
69 $this->httpRequest = $DIC->http()->request();
70 $this->tabs = $DIC->tabs();
71 $this->
user = $DIC->user();
◆ toggleLearningProgress()
ilContentPageKioskModeView::toggleLearningProgress |
( |
string |
$command | ) |
|
|
protected |
- Parameters
-
Definition at line 136 of file class.ilContentPageKioskModeView.php.
References ilLPStatusWrapper\_updateStatus(), ilLPMarks\getCompleted(), ilObjectLP\getInstance(), ilLPObjSettings\LP_MODE_MANUAL, and user().
Referenced by updateGet().
138 if (in_array($command, [
139 self::CMD_LP_TO_COMPLETED,
140 self::CMD_LP_TO_INCOMPLETE
144 $marks =
new ilLPMarks($this->contentPageObject->getId(), $this->
user->getId());
147 $new_state = ($command === self::CMD_LP_TO_COMPLETED);
148 $marks->setCompleted($new_state);
152 if ($old_state != $new_state) {
153 $this->lng->loadLanguageModule(
'trac');
154 $this->messages[] = $this->uiFactory->messageBox()->success(
155 $this->lng->txt(
'trac_updated_status')
static _updateStatus($a_obj_id, $a_usr_id, $a_obj=null, $a_percentage=false, $a_force_raise=false)
Update status.
static getInstance($a_obj_id)
◆ updateGet()
ilContentPageKioskModeView::updateGet |
( |
State |
$state, |
|
|
string |
$command, |
|
|
int |
$param = null |
|
) |
| |
◆ updatePost()
ilContentPageKioskModeView::updatePost |
( |
State |
$state, |
|
|
string |
$command, |
|
|
array |
$post |
|
) |
| |
◆ $contentPageObject
ilContentPageKioskModeView::$contentPageObject |
|
protected |
◆ $ctrl
ilContentPageKioskModeView::$ctrl |
|
protected |
◆ $httpRequest
ilContentPageKioskModeView::$httpRequest |
|
protected |
◆ $mainTemplate
ilContentPageKioskModeView::$mainTemplate |
|
protected |
◆ $messages
ilContentPageKioskModeView::$messages = [] |
|
protected |
◆ $tabs
ilContentPageKioskModeView::$tabs |
|
protected |
◆ $uiFactory
ilContentPageKioskModeView::$uiFactory |
|
protected |
◆ $uiRenderer
ilContentPageKioskModeView::$uiRenderer |
|
protected |
◆ $user
ilContentPageKioskModeView::$user |
|
protected |
◆ CMD_LP_TO_COMPLETED
const ilContentPageKioskModeView::CMD_LP_TO_COMPLETED = 'lp_completed' |
◆ CMD_LP_TO_INCOMPLETE
const ilContentPageKioskModeView::CMD_LP_TO_INCOMPLETE = 'lp_incomplete' |
The documentation for this class was generated from the following file: