ILIAS  release_8 Revision v8.24
ilTestInfoScreenToolbarGUI Class Reference
+ Inheritance diagram for ilTestInfoScreenToolbarGUI:
+ Collaboration diagram for ilTestInfoScreenToolbarGUI:

Public Member Functions

 __construct (ilDBInterface $db, ilAccessHandler $access, ilCtrl $ctrl, ilLanguage $lng, ilComponentRepository $component_repository)
 
 getGlobalToolbar ()
 
 setGlobalToolbar (ilToolbarGUI $globalToolbar)
 
 getTestOBJ ()
 
 setTestOBJ (ilObjTest $testOBJ)
 
 getTestQuestionSetConfig ()
 
 setTestQuestionSetConfig (ilTestQuestionSetConfig $testQuestionSetConfig)
 
 getTestPlayerGUI ()
 
 setTestPlayerGUI (ilTestPlayerAbstractGUI $testPlayerGUI)
 
 getTestSession ()
 
 setTestSession (ilTestSession $testSession)
 
 getTestSequence ()
 
 setTestSequence ($testSequence)
 
 getSessionLockString ()
 
 setSessionLockString ($sessionLockString)
 
 getInfoMessages ()
 
 addInfoMessage ($infoMessage)
 @ param string $infoMessage Could be. More...
 
 getFailureMessages ()
 
 addFailureMessage (string $failureMessage)
 
 setFormAction (string $a_val, bool $a_multipart=false, string $a_target="")
 Set form action (if form action is set, toolbar is wrapped into form tags) More...
 
 addButtonInstance (ilButtonBase $a_button)
 Add button instance. More...
 
 setCloseFormTag (bool $a_val)
 
 addInputItem (ilToolbarItem $a_item, bool $a_output_label=false)
 
 addFormInput ($formInput)
 
 clearItems ()
 
 build ()
 
 sendMessages ()
 
- Public Member Functions inherited from ilToolbarGUI
 setFormAction (string $a_val, bool $a_multipart=false, string $a_target="")
 Set form action (if form action is set, toolbar is wrapped into form tags) More...
 
 getFormAction ()
 
 setLeadingImage (string $a_img, string $a_alt)
 
 setHidden (bool $a_val)
 
 getHidden ()
 
 setId (string $a_val)
 
 getId ()
 
 setPreventDoubleSubmission (bool $a_val)
 
 getPreventDoubleSubmission ()
 
 addButton (string $a_txt, string $a_cmd, string $a_target="", ?int $a_acc_key=null, string $a_additional_attrs='', string $a_id="", string $a_class='submit')
 
 addFormButton (string $a_txt, string $a_cmd, ?int $a_acc_key=null, bool $a_primary=false, ?string $a_class=null)
 
 addInputItem (ilToolbarItem $a_item, bool $a_output_label=false)
 
 addStickyItem ( $a_item, bool $a_output_label=false)
 Add a sticky item. More...
 
 addButtonInstance (ilButtonBase $a_button)
 Add button instance. More...
 
 addDropDown (string $a_txt, string $a_dd_html)
 
 addAdvancedSelectionList (ilAdvancedSelectionListGUI $adv)
 
 addSeparator ()
 
 addText (string $a_text)
 
 addSpacer (string $a_width=null)
 
 addComponent (\ILIAS\UI\Component\Component $a_comp)
 
 addLink (string $a_caption, string $a_url, bool $a_disabled=false)
 
 setOpenFormTag (bool $a_val)
 
 getOpenFormTag ()
 
 setCloseFormTag (bool $a_val)
 
 getCloseFormTag ()
 
 setFormName (string $a_val)
 
 getFormName ()
 
 getGroupedItems ()
 Get all groups (items separated by a separator) More...
 
 getItems ()
 
 setItems (array $items)
 

Protected Member Functions

 populateMessage ($message)
 
- Protected Member Functions inherited from ilToolbarGUI
 applyAutoStickyToSingleElement ()
 If the toolbar consists of only one button, make it sticky Note: Atm this is only possible for buttons. More...
 

Protected Attributes

ILIAS DI Container $DIC
 
ilDBInterface $db
 
ilAccessHandler $access
 
ilCtrl $ctrl
 
ilComponentRepository $component_repository
 
ilObjTest $testOBJ = null
 
ilTestQuestionSetConfig $testQuestionSetConfig = null
 
ilTestPlayerAbstractGUI $testPlayerGUI = null
 
ilTestSession $testSession = null
 
 $testSequence
 
- Protected Attributes inherited from ilToolbarGUI
ilLanguage $lng
 
string $id = ''
 
string $form_action = ''
 
bool $hidden = false
 
array $lead_img
 
bool $open_form_tag = true
 
bool $close_form_tag = true
 
string $form_target = ""
 
string $form_name = ""
 
bool $prevent_double_submission = false
 
array $sticky_items = array()
 
bool $has_separator = false
 
ILIAS DI UIServices $ui
 
bool $multipart = false
 

Private Member Functions

 getClassName ($target)
 
 getClassNameArray ($target)
 
 getClassPath ($target)
 
 setParameter ($target, $parameter, $value)
 
 buildLinkTarget ($target, $cmd=null)
 
 buildFormAction ($target)
 
 ensureInitialisedSessionLockString ()
 
 buildSessionLockString ()
 
 areSkillLevelThresholdsMissing ()
 
 getSkillLevelThresholdsMissingInfo ()
 
 hasFixedQuestionSetSkillAssignsLowerThanBarrier ()
 
 getSkillAssignBarrierInfo ()
 

Private Attributes

ilToolbarGUI $globalToolbar = null
 
ilGlobalTemplateInterface $main_tpl
 
 $sessionLockString
 
array $infoMessages = array()
 
array $failureMessages = array()
 

Static Private Attributes

static array $TARGET_CLASS_PATH_BASE = array('ilRepositoryGUI', 'ilObjTestGUI')
 

Additional Inherited Members

- Data Fields inherited from ilToolbarGUI
array $items = array()
 
- Static Protected Attributes inherited from ilToolbarGUI
static int $instances = 0
 

Detailed Description

Definition at line 25 of file class.ilTestInfoScreenToolbarGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilTestInfoScreenToolbarGUI::__construct ( ilDBInterface  $db,
ilAccessHandler  $access,
ilCtrl  $ctrl,
ilLanguage  $lng,
ilComponentRepository  $component_repository 
)

Definition at line 55 of file class.ilTestInfoScreenToolbarGUI.php.

61 {
62 global $DIC;
63 $this->main_tpl = $DIC->ui()->mainTemplate(); /* @var ILIAS\DI\Container $DIC */
64 $this->DIC = $DIC;
65 $this->db = $db;
66 $this->access = $access;
67 $this->ctrl = $ctrl;
68 $this->lng = $lng;
69 $this->component_repository = $component_repository;
70 }

References $access, $component_repository, $ctrl, $db, $DIC, ilToolbarGUI\$lng, ILIAS\Repository\access(), ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

Member Function Documentation

◆ addButtonInstance()

ilTestInfoScreenToolbarGUI::addButtonInstance ( ilButtonBase  $a_button)

Add button instance.

Parameters
ilButtonBase$a_button

Reimplemented from ilToolbarGUI.

Definition at line 183 of file class.ilTestInfoScreenToolbarGUI.php.

183 : void
184 {
185 if ($this->globalToolbar instanceof parent) {
186 $this->globalToolbar->addButtonInstance($a_button);
187 } else {
188 parent::addButtonInstance($a_button);
189 }
190 }

◆ addFailureMessage()

ilTestInfoScreenToolbarGUI::addFailureMessage ( string  $failureMessage)

Definition at line 166 of file class.ilTestInfoScreenToolbarGUI.php.

166 : void
167 {
168 $this->failureMessages[] = $failureMessage;
169 }

◆ addFormInput()

ilTestInfoScreenToolbarGUI::addFormInput (   $formInput)

Definition at line 212 of file class.ilTestInfoScreenToolbarGUI.php.

212 : void
213 {
214 if ($this->globalToolbar instanceof parent) {
215 $this->globalToolbar->addFormInput($formInput);
216 }
217 }

◆ addInfoMessage()

ilTestInfoScreenToolbarGUI::addInfoMessage (   $infoMessage)

@ param string $infoMessage Could be.

Doesn't have to.

Definition at line 156 of file class.ilTestInfoScreenToolbarGUI.php.

156 : void
157 {
158 $this->infoMessages[] = $infoMessage;
159 }

◆ addInputItem()

ilTestInfoScreenToolbarGUI::addInputItem ( ilToolbarItem  $a_item,
bool  $a_output_label = false 
)

Reimplemented from ilToolbarGUI.

Definition at line 201 of file class.ilTestInfoScreenToolbarGUI.php.

204 : void {
205 if ($this->globalToolbar instanceof parent) {
206 $this->globalToolbar->addInputItem($a_item, $a_output_label);
207 } else {
208 parent::addInputItem($a_item, $a_output_label);
209 }
210 }

◆ areSkillLevelThresholdsMissing()

ilTestInfoScreenToolbarGUI::areSkillLevelThresholdsMissing ( )
private

Definition at line 278 of file class.ilTestInfoScreenToolbarGUI.php.

278 : bool
279 {
280 if (!$this->getTestOBJ()->isSkillServiceEnabled()) {
281 return false;
282 }
283
284 $questionContainerId = $this->getTestOBJ()->getId();
285
286 require_once 'Modules/TestQuestionPool/classes/class.ilAssQuestionSkillAssignmentList.php';
287 require_once 'Modules/Test/classes/class.ilTestSkillLevelThreshold.php';
288
289 $assignmentList = new ilAssQuestionSkillAssignmentList($this->db);
290 $assignmentList->setParentObjId($questionContainerId);
291 $assignmentList->loadFromDb();
292
293 foreach ($assignmentList->getUniqueAssignedSkills() as $data) {
294 foreach ($data['skill']->getLevelData() as $level) {
295 $treshold = new ilTestSkillLevelThreshold($this->db);
296 $treshold->setTestId($this->getTestOBJ()->getTestId());
297 $treshold->setSkillBaseId($data['skill_base_id']);
298 $treshold->setSkillTrefId($data['skill_tref_id']);
299 $treshold->setSkillLevelId($level['id']);
300
301 if (!$treshold->dbRecordExists()) {
302 return true;
303 }
304 }
305 }
306
307 return false;
308 }

References $data.

◆ build()

ilTestInfoScreenToolbarGUI::build ( )

Definition at line 353 of file class.ilTestInfoScreenToolbarGUI.php.

353 : void
354 {
355 if (!$this->testOBJ->isDynamicTest()) {
357
358 $this->setParameter($this->getTestPlayerGUI(), 'lock', $this->getSessionLockString());
359 $this->setParameter($this->getTestPlayerGUI(), 'sequence', $this->getTestSession()->getLastSequence());
360 $this->setParameter('ilObjTestGUI', 'ref_id', $this->getTestOBJ()->getRefId());
361
362 $this->setFormAction($this->buildFormAction($this->getTestPlayerGUI()));
363 }
364
365 $online_access = false;
366 if ($this->getTestOBJ()->getFixedParticipants()) {
367 include_once "./Modules/Test/classes/class.ilObjTestAccess.php";
368 $online_access_result = ilObjTestAccess::_lookupOnlineTestAccess($this->getTestOBJ()->getId(), $this->getTestSession()->getUserId());
369 if ($online_access_result === true) {
370 $online_access = true;
371 } else {
372 $this->addInfoMessage($online_access_result);
373 }
374 }
375
376 if (!$this->getTestOBJ()->getOfflineStatus() && $this->getTestOBJ()->isComplete($this->getTestQuestionSetConfig())) {
377 if ((!$this->getTestOBJ()->getFixedParticipants() || $online_access) && $this->access->checkAccess("read", "", $this->getTestOBJ()->getRefId())) {
378 $executable = $this->getTestOBJ()->isExecutable(
379 $this->getTestSession(),
380 $this->getTestSession()->getUserId(),
381 $allowPassIncrease = true
382 );
383
384 if ($executable["executable"]) {
385 if ($this->getTestOBJ()->areObligationsEnabled() && $this->getTestOBJ()->hasObligations($this->getTestOBJ()->getTestId())) {
386 $this->addInfoMessage($this->lng->txt('tst_test_contains_obligatory_questions'));
387 }
388
389 if ($this->getTestSession()->getActiveId() > 0) {
390 // resume test
391 require_once 'Modules/Test/classes/class.ilTestPassesSelector.php';
392 $testPassesSelector = new ilTestPassesSelector($this->db, $this->getTestOBJ());
393 $testPassesSelector->setActiveId($this->getTestSession()->getActiveId());
394 $testPassesSelector->setLastFinishedPass($this->getTestSession()->getLastFinishedPass());
395
396 $closedPasses = $testPassesSelector->getClosedPasses();
397 $existingPasses = $testPassesSelector->getExistingPasses();
398
399 if ($existingPasses > $closedPasses) {
401 $btn->setCaption('tst_resume_test');
402 $btn->setCommand('resumePlayer');
403 $btn->setPrimary(true);
404 $this->addButtonInstance($btn);
405 } else {
407 $btn->setCaption($this->getTestOBJ()->getStartTestLabel($this->getTestSession()->getActiveId()), false);
408 $btn->setCommand('startPlayer');
409 $btn->setPrimary(true);
410 $this->addButtonInstance($btn);
411 }
412 } else {
413 // start new test
415 $btn->setCaption($this->getTestOBJ()->getStartTestLabel($this->getTestSession()->getActiveId()), false);
416 $btn->setCommand('startPlayer');
417 $btn->setPrimary(true);
418 $this->addButtonInstance($btn);
419 }
420 } else {
421 $this->addInfoMessage($executable['errormessage']);
422 }
423 }
424
425 if ($this->DIC->user()->getId() == ANONYMOUS_USER_ID) {
426 if ($this->getItems()) {
427 $this->addSeparator();
428 }
429
430 require_once 'Services/Form/classes/class.ilTextInputGUI.php';
431 $anonymous_id = new ilTextInputGUI($this->lng->txt('enter_anonymous_code'), 'anonymous_id');
432 $anonymous_id->setSize(8);
433 $this->addInputItem($anonymous_id, true);
434 $button = ilSubmitButton::getInstance();
435 $button->setCaption('submit');
436 $button->setCommand('setAnonymousId');
437 $this->addButtonInstance($button);
438 }
439 }
440 if ($this->getTestOBJ()->getOfflineStatus() && !$this->getTestQuestionSetConfig()->areDepenciesBroken()) {
441 $message = $this->lng->txt("test_is_offline");
442
443 $links = array();
444
445 if ($this->access->checkAccess("write", "", $this->getTestOBJ()->getRefId())) {
446 $links[] = $this->DIC->ui()->factory()->link()->standard(
447 $this->DIC->language()->txt('test_edit_settings'),
448 $this->buildLinkTarget('ilobjtestsettingsgeneralgui')
449 );
450 }
451
452 $msgBox = $this->DIC->ui()->factory()->messageBox()->info($message)->withLinks($links);
453
454 $this->populateMessage($this->DIC->ui()->renderer()->render($msgBox));
455 }
456
457 if ($this->access->checkAccess("write", "", $this->getTestOBJ()->getRefId())) {
458 require_once 'Modules/TestQuestionPool/classes/questions/class.ilAssQuestionSkillAssignmentImportFails.php';
459 $qsaImportFails = new ilAssQuestionSkillAssignmentImportFails($this->testOBJ->getId());
460 require_once 'Modules/Test/classes/class.ilTestSkillLevelThresholdImportFails.php';
461 $sltImportFails = new ilTestSkillLevelThresholdImportFails($this->testOBJ->getId());
462
463 if ($qsaImportFails->failedImportsRegistered() || $sltImportFails->failedImportsRegistered()) {
464 $importFailsMsg = array();
465
466 if ($qsaImportFails->failedImportsRegistered()) {
467 $importFailsMsg[] = $qsaImportFails->getFailedImportsMessage($this->lng);
468 }
469
470 if ($sltImportFails->failedImportsRegistered()) {
471 $importFailsMsg[] = $sltImportFails->getFailedImportsMessage($this->lng);
472 }
473
474 $message = implode('<br />', $importFailsMsg);
475
476 $button = $this->DIC->ui()->factory()->button()->standard(
477 $this->DIC->language()->txt('ass_skl_import_fails_remove_btn'),
478 $this->DIC->ctrl()->getLinkTargetByClass('ilObjTestGUI', 'removeImportFails')
479 );
480
481 $msgBox = $this->DIC->ui()->factory()->messageBox()->failure($message)->withButtons(array($button));
482
483 $this->populateMessage($this->DIC->ui()->renderer()->render($msgBox));
484 } elseif ($this->getTestOBJ()->isSkillServiceToBeConsidered()) {
485 if ($this->areSkillLevelThresholdsMissing()) {
487 }
488
491 }
492 }
493
494 if ($this->getTestQuestionSetConfig()->areDepenciesBroken()) {
495 $this->addFailureMessage($this->getTestQuestionSetConfig()->getDepenciesBrokenMessage($this->lng));
496
497 $this->clearItems();
498 } elseif ($this->getTestQuestionSetConfig()->areDepenciesInVulnerableState()) {
499 $this->addInfoMessage($this->getTestQuestionSetConfig()->getDepenciesInVulnerableStateMessage($this->lng));
500 }
501 }
502 }
static _lookupOnlineTestAccess($a_test_id, $a_user_id)
Checks if a user is allowd to run an online exam.
addInfoMessage($infoMessage)
@ param string $infoMessage Could be.
addButtonInstance(ilButtonBase $a_button)
Add button instance.
setParameter($target, $parameter, $value)
addInputItem(ilToolbarItem $a_item, bool $a_output_label=false)
setFormAction(string $a_val, bool $a_multipart=false, string $a_target="")
Set form action (if form action is set, toolbar is wrapped into form tags)
This class represents a text property in a property form.
const ANONYMOUS_USER_ID
Definition: constants.php:27
$message
Definition: xapiexit.php:32

References $message, ilObjTestAccess\_lookupOnlineTestAccess(), ILIAS\Repository\access(), ANONYMOUS_USER_ID, ILIAS\Survey\Mode\getId(), ilSubmitButton\getInstance(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ buildFormAction()

ilTestInfoScreenToolbarGUI::buildFormAction (   $target)
private

Definition at line 261 of file class.ilTestInfoScreenToolbarGUI.php.

261 : string
262 {
263 return $this->ctrl->getFormActionByClass($this->getClassPath($target));
264 }

References ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ buildLinkTarget()

ilTestInfoScreenToolbarGUI::buildLinkTarget (   $target,
  $cmd = null 
)
private

Definition at line 256 of file class.ilTestInfoScreenToolbarGUI.php.

256 : string
257 {
258 return $this->ctrl->getLinkTargetByClass($this->getClassPath($target), $cmd);
259 }

References ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ buildSessionLockString()

ilTestInfoScreenToolbarGUI::buildSessionLockString ( )
private

Definition at line 273 of file class.ilTestInfoScreenToolbarGUI.php.

273 : string
274 {
275 return md5($_COOKIE[session_name()] . time());
276 }
$_COOKIE[session_name()]
Definition: xapitoken.php:54

References $_COOKIE.

◆ clearItems()

ilTestInfoScreenToolbarGUI::clearItems ( )

Definition at line 219 of file class.ilTestInfoScreenToolbarGUI.php.

219 : void
220 {
221 if ($this->globalToolbar instanceof parent) {
222 $this->globalToolbar->setItems(array());
223 } else {
224 $this->setItems(array());
225 }
226 }
setItems(array $items)

◆ ensureInitialisedSessionLockString()

ilTestInfoScreenToolbarGUI::ensureInitialisedSessionLockString ( )
private

Definition at line 266 of file class.ilTestInfoScreenToolbarGUI.php.

266 : void
267 {
268 if (!strlen($this->getSessionLockString())) {
270 }
271 }

◆ getClassName()

ilTestInfoScreenToolbarGUI::getClassName (   $target)
private

Definition at line 228 of file class.ilTestInfoScreenToolbarGUI.php.

229 {
230 if (is_object($target)) {
231 $target = get_class($target);
232 }
233
234 return $target;
235 }

◆ getClassNameArray()

ilTestInfoScreenToolbarGUI::getClassNameArray (   $target)
private

Definition at line 237 of file class.ilTestInfoScreenToolbarGUI.php.

237 : array
238 {
239 if (is_array($target)) {
240 return $target;
241 }
242
243 return array($this->getClassName($target));
244 }

◆ getClassPath()

ilTestInfoScreenToolbarGUI::getClassPath (   $target)
private

Definition at line 246 of file class.ilTestInfoScreenToolbarGUI.php.

246 : array
247 {
248 return array_merge(self::$TARGET_CLASS_PATH_BASE, $this->getClassNameArray($target));
249 }

◆ getFailureMessages()

ilTestInfoScreenToolbarGUI::getFailureMessages ( )

Definition at line 161 of file class.ilTestInfoScreenToolbarGUI.php.

161 : array
162 {
164 }

References $failureMessages.

◆ getGlobalToolbar()

ilTestInfoScreenToolbarGUI::getGlobalToolbar ( )

Definition at line 72 of file class.ilTestInfoScreenToolbarGUI.php.

73 {
75 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References $globalToolbar.

◆ getInfoMessages()

ilTestInfoScreenToolbarGUI::getInfoMessages ( )

Definition at line 148 of file class.ilTestInfoScreenToolbarGUI.php.

148 : array
149 {
150 return $this->infoMessages;
151 }

References $infoMessages.

◆ getSessionLockString()

ilTestInfoScreenToolbarGUI::getSessionLockString ( )

Definition at line 138 of file class.ilTestInfoScreenToolbarGUI.php.

References $sessionLockString.

◆ getSkillAssignBarrierInfo()

ilTestInfoScreenToolbarGUI::getSkillAssignBarrierInfo ( )
private

Definition at line 343 of file class.ilTestInfoScreenToolbarGUI.php.

343 : string
344 {
345 require_once 'Modules/Test/classes/class.ilObjAssessmentFolder.php';
346
347 return sprintf(
348 $this->lng->txt('tst_skill_triggerings_num_req_answers_not_reached_warn'),
350 );
351 }

References ilObjAssessmentFolder\getSkillTriggerAnswerNumberBarrier(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getSkillLevelThresholdsMissingInfo()

ilTestInfoScreenToolbarGUI::getSkillLevelThresholdsMissingInfo ( )
private

Definition at line 310 of file class.ilTestInfoScreenToolbarGUI.php.

310 : string
311 {
312 $message = $this->lng->txt('tst_skl_level_thresholds_missing');
313
314 $linkTarget = $this->buildLinkTarget(
315 array('ilTestSkillAdministrationGUI', 'ilTestSkillLevelThresholdsGUI'),
317 );
318
319 $link = $this->DIC->ui()->factory()->link()->standard(
320 $this->DIC->language()->txt('tst_skl_level_thresholds_link'),
321 $linkTarget
322 );
323
324 $msgBox = $this->DIC->ui()->factory()->messageBox()->failure($message)->withLinks(array($link));
325
326 return $this->DIC->ui()->renderer()->render($msgBox);
327 }

References $message, ilTestSkillLevelThresholdsGUI\CMD_SHOW_SKILL_THRESHOLDS, and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getTestOBJ()

ilTestInfoScreenToolbarGUI::getTestOBJ ( )

Definition at line 82 of file class.ilTestInfoScreenToolbarGUI.php.

References $testOBJ.

◆ getTestPlayerGUI()

ilTestInfoScreenToolbarGUI::getTestPlayerGUI ( )

Definition at line 102 of file class.ilTestInfoScreenToolbarGUI.php.

103 {
105 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References $testPlayerGUI.

◆ getTestQuestionSetConfig()

ilTestInfoScreenToolbarGUI::getTestQuestionSetConfig ( )

◆ getTestSequence()

ilTestInfoScreenToolbarGUI::getTestSequence ( )
Returns
ilTestSequence|ilTestSequenceDynamicQuestionSet

Definition at line 125 of file class.ilTestInfoScreenToolbarGUI.php.

References $testSequence.

◆ getTestSession()

ilTestInfoScreenToolbarGUI::getTestSession ( )

Definition at line 112 of file class.ilTestInfoScreenToolbarGUI.php.

113 {
114 return $this->testSession;
115 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References $testSession.

◆ hasFixedQuestionSetSkillAssignsLowerThanBarrier()

ilTestInfoScreenToolbarGUI::hasFixedQuestionSetSkillAssignsLowerThanBarrier ( )
private

Definition at line 329 of file class.ilTestInfoScreenToolbarGUI.php.

329 : bool
330 {
331 if (!$this->testOBJ->isFixedTest()) {
332 return false;
333 }
334
335 require_once 'Modules/TestQuestionPool/classes/class.ilAssQuestionSkillAssignmentList.php';
336 $assignmentList = new ilAssQuestionSkillAssignmentList($this->db);
337 $assignmentList->setParentObjId($this->testOBJ->getId());
338 $assignmentList->loadFromDb();
339
340 return $assignmentList->hasSkillsAssignedLowerThanBarrier();
341 }

◆ populateMessage()

ilTestInfoScreenToolbarGUI::populateMessage (   $message)
protected

Definition at line 504 of file class.ilTestInfoScreenToolbarGUI.php.

504 : void
505 {
506 $this->DIC->ui()->mainTemplate()->setCurrentBlock('mess');
507 $this->DIC->ui()->mainTemplate()->setVariable('MESSAGE', $message);
508 $this->DIC->ui()->mainTemplate()->parseCurrentBlock();
509 }

References $message.

◆ sendMessages()

ilTestInfoScreenToolbarGUI::sendMessages ( )

Definition at line 511 of file class.ilTestInfoScreenToolbarGUI.php.

511 : void
512 {
513 $info_messages = $this->getInfoMessages();
514 if ($info_messages !== array()) {
515 $this->main_tpl->setOnScreenMessage('info', array_pop($info_messages));
516 }
517
518 $failure_messages = $this->getFailureMessages();
519 if ($failure_messages !== array()) {
520 $this->main_tpl->setOnScreenMessage('failure', array_pop($failure_messages));
521 }
522 }

◆ setCloseFormTag()

ilTestInfoScreenToolbarGUI::setCloseFormTag ( bool  $a_val)

Reimplemented from ilToolbarGUI.

Definition at line 192 of file class.ilTestInfoScreenToolbarGUI.php.

192 : void
193 {
194 if ($this->globalToolbar instanceof parent) {
195 $this->globalToolbar->setCloseFormTag($a_val);
196 } else {
197 parent::setCloseFormTag($a_val);
198 }
199 }

◆ setFormAction()

ilTestInfoScreenToolbarGUI::setFormAction ( string  $a_val,
bool  $a_multipart = false,
string  $a_target = "" 
)

Set form action (if form action is set, toolbar is wrapped into form tags)

Reimplemented from ilToolbarGUI.

Definition at line 171 of file class.ilTestInfoScreenToolbarGUI.php.

175 : void {
176 if ($this->globalToolbar instanceof parent) {
177 $this->globalToolbar->setFormAction($a_val, $a_multipart, $a_target);
178 } else {
179 parent::setFormAction($a_val, $a_multipart, $a_target);
180 }
181 }

◆ setGlobalToolbar()

ilTestInfoScreenToolbarGUI::setGlobalToolbar ( ilToolbarGUI  $globalToolbar)

Definition at line 77 of file class.ilTestInfoScreenToolbarGUI.php.

77 : void
78 {
79 $this->globalToolbar = $globalToolbar;
80 }

References $globalToolbar.

◆ setParameter()

ilTestInfoScreenToolbarGUI::setParameter (   $target,
  $parameter,
  $value 
)
private

Definition at line 251 of file class.ilTestInfoScreenToolbarGUI.php.

251 : void
252 {
253 $this->ctrl->setParameterByClass($this->getClassName($target), $parameter, $value);
254 }

References ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ setSessionLockString()

ilTestInfoScreenToolbarGUI::setSessionLockString (   $sessionLockString)

Definition at line 143 of file class.ilTestInfoScreenToolbarGUI.php.

143 : void
144 {
145 $this->sessionLockString = $sessionLockString;
146 }

References $sessionLockString.

◆ setTestOBJ()

ilTestInfoScreenToolbarGUI::setTestOBJ ( ilObjTest  $testOBJ)

Definition at line 87 of file class.ilTestInfoScreenToolbarGUI.php.

87 : void
88 {
89 $this->testOBJ = $testOBJ;
90 }

References $testOBJ.

◆ setTestPlayerGUI()

ilTestInfoScreenToolbarGUI::setTestPlayerGUI ( ilTestPlayerAbstractGUI  $testPlayerGUI)

Definition at line 107 of file class.ilTestInfoScreenToolbarGUI.php.

107 : void
108 {
109 $this->testPlayerGUI = $testPlayerGUI;
110 }

References $testPlayerGUI.

◆ setTestQuestionSetConfig()

ilTestInfoScreenToolbarGUI::setTestQuestionSetConfig ( ilTestQuestionSetConfig  $testQuestionSetConfig)

Definition at line 97 of file class.ilTestInfoScreenToolbarGUI.php.

97 : void
98 {
99 $this->testQuestionSetConfig = $testQuestionSetConfig;
100 }

References $testQuestionSetConfig.

◆ setTestSequence()

ilTestInfoScreenToolbarGUI::setTestSequence (   $testSequence)
Parameters
ilTestSequence | ilTestSequenceDynamicQuestionSet$testSequence

Definition at line 133 of file class.ilTestInfoScreenToolbarGUI.php.

133 : void
134 {
135 $this->testSequence = $testSequence;
136 }

References $testSequence.

◆ setTestSession()

ilTestInfoScreenToolbarGUI::setTestSession ( ilTestSession  $testSession)

Definition at line 117 of file class.ilTestInfoScreenToolbarGUI.php.

117 : void
118 {
119 $this->testSession = $testSession;
120 }

References $testSession.

Field Documentation

◆ $access

ilAccessHandler ilTestInfoScreenToolbarGUI::$access
protected

Definition at line 33 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by __construct().

◆ $component_repository

ilComponentRepository ilTestInfoScreenToolbarGUI::$component_repository
protected

Definition at line 35 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by __construct().

◆ $ctrl

ilCtrl ilTestInfoScreenToolbarGUI::$ctrl
protected

Definition at line 34 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by __construct().

◆ $db

ilDBInterface ilTestInfoScreenToolbarGUI::$db
protected

Definition at line 32 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by __construct().

◆ $DIC

ILIAS DI Container ilTestInfoScreenToolbarGUI::$DIC
protected

Definition at line 29 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by __construct().

◆ $failureMessages

array ilTestInfoScreenToolbarGUI::$failureMessages = array()
private

Definition at line 53 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getFailureMessages().

◆ $globalToolbar

ilToolbarGUI ilTestInfoScreenToolbarGUI::$globalToolbar = null
private

Definition at line 30 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getGlobalToolbar(), and setGlobalToolbar().

◆ $infoMessages

array ilTestInfoScreenToolbarGUI::$infoMessages = array()
private

Definition at line 52 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getInfoMessages().

◆ $main_tpl

ilGlobalTemplateInterface ilTestInfoScreenToolbarGUI::$main_tpl
private

Definition at line 36 of file class.ilTestInfoScreenToolbarGUI.php.

◆ $sessionLockString

ilTestInfoScreenToolbarGUI::$sessionLockString
private

◆ $TARGET_CLASS_PATH_BASE

array ilTestInfoScreenToolbarGUI::$TARGET_CLASS_PATH_BASE = array('ilRepositoryGUI', 'ilObjTestGUI')
staticprivate

Definition at line 27 of file class.ilTestInfoScreenToolbarGUI.php.

◆ $testOBJ

ilObjTest ilTestInfoScreenToolbarGUI::$testOBJ = null
protected

Definition at line 38 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getTestOBJ(), and setTestOBJ().

◆ $testPlayerGUI

ilTestPlayerAbstractGUI ilTestInfoScreenToolbarGUI::$testPlayerGUI = null
protected

Definition at line 40 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getTestPlayerGUI(), and setTestPlayerGUI().

◆ $testQuestionSetConfig

ilTestQuestionSetConfig ilTestInfoScreenToolbarGUI::$testQuestionSetConfig = null
protected

◆ $testSequence

ilTestInfoScreenToolbarGUI::$testSequence
protected

Definition at line 46 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getTestSequence(), and setTestSequence().

◆ $testSession

ilTestSession ilTestInfoScreenToolbarGUI::$testSession = null
protected

Definition at line 41 of file class.ilTestInfoScreenToolbarGUI.php.

Referenced by getTestSession(), and setTestSession().


The documentation for this class was generated from the following file: