ILIAS
release_8 Revision v8.19
|
Basic class for all survey question types The SurveyQuestionGUI class defines and encapsulates basic methods and attributes for survey question types to be used for all parent classes. More...
Public Member Functions | |
__construct ($a_id=-1) | |
setQuestionTabs () | |
executeCommand () | |
getQuestionType () | |
Returns the question type string. More... | |
setBackUrl (string $a_url) | |
setQuestionTabsForClass (string $guiclass) | |
getPrintView (int $question_title=1, bool $show_questiontext=true, ?int $survey_id=null, ?array $working_data=null) | |
preview () | |
getWorkingForm (array $working_data=null, int $question_title=1, bool $show_questiontext=true, string $error_message="", int $survey_id=null, bool $compress_view=false) | |
material (bool $checkonly=false) | |
Material tab of the survey questions. More... | |
deleteMaterial () | |
addMaterial () | |
Add materials to a question. More... | |
removeMaterial () | |
cancelExplorer () | |
addPG () | |
addST () | |
addGIT () | |
linkChilds () | |
savePhrase (bool $a_reload=false) | |
Creates an output to save the current answers as a phrase. More... | |
confirmSavePhrase () | |
Save a new phrase to the database. More... | |
Static Public Member Functions | |
static | _getQuestionGUI (?string $questiontype, int $question_id=-1) |
Creates a question gui representation. More... | |
static | _getGUIClassNameForId (int $a_q_id) |
static | _getClassNameForQType (string $q_type) |
Data Fields | |
SurveyQuestion | $object = null |
Protected Member Functions | |
initObject () | |
outQuestionText (ilTemplate $template) | |
initEditForm () | |
addCommandButtons (ilPropertyFormGUI $a_form) | |
editQuestion (ilPropertyFormGUI $a_form=null) | |
saveSync () | |
saveReturn () | |
saveForm () | |
save (bool $a_return=false, bool $a_sync=false) | |
copySyncForm () | |
syncCopies () | |
originalSyncForm () | |
sync () | |
cancelSync () | |
redirectAfterSaving (bool $a_return=false) | |
Redirect to calling survey or to edit form. More... | |
cancel () | |
validateEditForm (ilPropertyFormGUI $a_form) | |
addFieldsToEditForm (ilPropertyFormGUI $a_form) | |
importEditFormValues (ilPropertyFormGUI $a_form) | |
getPrintViewQuestionTitle (int $question_title=1) | |
getQuestionTitle (int $question_title_mode=1) | |
getMaterialOutput () | |
Creates the HTML output of the question material(s) More... | |
initPhrasesForm () | |
addPhrase (ilPropertyFormGUI $a_form=null) | |
Creates an output for the addition of phrases. More... | |
addSelectedPhrase () | |
renderStatisticsDetailsTable (array $a_head, array $a_rows, array $a_foot=null) | |
Protected Attributes | |
EditingGUIRequest | $request |
EditManager | $edit_manager |
ilRbacSystem | $rbacsystem |
ilObjUser | $user |
ilAccessHandler | $access |
ilTree | $tree |
ilToolbarGUI | $toolbar |
ilTabsGUI | $tabs |
ilGlobalTemplateInterface | $tpl |
ilLanguage | $lng |
ilCtrl | $ctrl |
array | $cumulated = [] |
string | $parent_url = "" |
ilLogger | $log |
Basic class for all survey question types The SurveyQuestionGUI class defines and encapsulates basic methods and attributes for survey question types to be used for all parent classes.
Definition at line 28 of file class.SurveyQuestionGUI.php.
SurveyQuestionGUI::__construct | ( | $a_id = -1 | ) |
Definition at line 46 of file class.SurveyQuestionGUI.php.
References $DIC, $lng, $tpl, ILIAS\Repository\access(), ILIAS\Repository\ctrl(), ilLoggerFactory\getLogger(), initObject(), ILIAS\Repository\lng(), setQuestionTabs(), ILIAS\Repository\tabs(), ILIAS\Repository\toolbar(), and ILIAS\Repository\user().
|
static |
Definition at line 131 of file class.SurveyQuestionGUI.php.
Referenced by _getGUIClassNameForId().
|
static |
Definition at line 124 of file class.SurveyQuestionGUI.php.
References _getClassNameForQType(), and SurveyQuestion\_getQuestionType().
Referenced by ilSurveyQuestionsTableGUI\fillRow().
|
static |
Creates a question gui representation.
Definition at line 111 of file class.SurveyQuestionGUI.php.
References SurveyQuestion\_getQuestionType(), and SurveyQuestion\_includeClass().
Referenced by ilSurveyPageEditGUI\addQuestion(), ilObjSurveyQuestionPoolGUI\createQuestionObject(), ilObjSurveyQuestionPoolGUI\executeCommand(), ilSurveyEditorGUI\executeCommand(), ilSurveyEditorGUI\executeCreateQuestionObject(), ilObjSurvey\getQuestionGUI(), and ilObjSurveyQuestionPoolGUI\previewObject().
|
protected |
Definition at line 297 of file class.SurveyQuestionGUI.php.
References ilObject\_lookupType(), ilPropertyFormGUI\addCommandButton(), ILIAS\Repository\lng(), and ILIAS\Repository\object().
Referenced by initEditForm().
|
abstractprotected |
SurveyQuestionGUI::addGIT | ( | ) |
Definition at line 837 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().
SurveyQuestionGUI::addMaterial | ( | ) |
Add materials to a question.
Definition at line 757 of file class.SurveyQuestionGUI.php.
References $panel, $tabs, $toolbar, ilToolbarGUI\addButton(), ILIAS\Repository\ctrl(), ilPanelGUI\getInstance(), ILIAS\Repository\lng(), material(), and ilTreeExplorerGUI\setPathOpen().
SurveyQuestionGUI::addPG | ( | ) |
Definition at line 819 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().
|
protected |
Creates an output for the addition of phrases.
Definition at line 970 of file class.SurveyQuestionGUI.php.
References $tabs, ilTabsGUI\activateTab(), ilPropertyFormGUI\getHTML(), initPhrasesForm(), and saveForm().
Referenced by addSelectedPhrase().
|
protected |
Definition at line 988 of file class.SurveyQuestionGUI.php.
References $valid, addPhrase(), ILIAS\Repository\ctrl(), initPhrasesForm(), ILIAS\Repository\lng(), and ILIAS\Repository\object().
SurveyQuestionGUI::addST | ( | ) |
Definition at line 828 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().
|
protected |
Definition at line 527 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ilUtil\redirect().
SurveyQuestionGUI::cancelExplorer | ( | ) |
Definition at line 812 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().
|
protected |
Definition at line 479 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\lng(), and redirectAfterSaving().
SurveyQuestionGUI::confirmSavePhrase | ( | ) |
Save a new phrase to the database.
Definition at line 1075 of file class.SurveyQuestionGUI.php.
References $valid, ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ILIAS\Repository\object(), and savePhrase().
|
protected |
Definition at line 393 of file class.SurveyQuestionGUI.php.
References $tabs, and ilTabsGUI\activateTab().
Referenced by syncCopies().
SurveyQuestionGUI::deleteMaterial | ( | ) |
Definition at line 742 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().
|
protected |
Definition at line 308 of file class.SurveyQuestionGUI.php.
References $tabs, ilTabsGUI\activateTab(), and initEditForm().
Referenced by removeMaterial(), save(), and saveForm().
SurveyQuestionGUI::executeCommand | ( | ) |
Definition at line 95 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl().
|
protected |
Creates the HTML output of the question material(s)
Definition at line 638 of file class.SurveyQuestionGUI.php.
References SurveyQuestion\_getInternalLinkHref(), ILIAS\Repository\lng(), ILIAS\Repository\object(), and ilLegacyFormElementsUtil\prepareFormOutput().
Referenced by SurveyTextQuestionGUI\getWorkingForm(), SurveyMetricQuestionGUI\getWorkingForm(), SurveySingleChoiceQuestionGUI\getWorkingForm(), SurveyMultipleChoiceQuestionGUI\getWorkingForm(), and SurveyMatrixQuestionGUI\getWorkingForm().
|
abstract |
|
protected |
Definition at line 552 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\object(), ilLegacyFormElementsUtil\prepareFormOutput(), ilObjSurvey\PRINT_HIDE_LABELS, and ilObjSurvey\PRINT_SHOW_LABELS.
Referenced by SurveyTextQuestionGUI\getPrintView(), SurveySingleChoiceQuestionGUI\getPrintView(), SurveyMetricQuestionGUI\getPrintView(), SurveyMultipleChoiceQuestionGUI\getPrintView(), and SurveyMatrixQuestionGUI\getPrintView().
|
protected |
Definition at line 578 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\object(), ilObjSurvey\PRINT_HIDE_LABELS, and ilObjSurvey\PRINT_SHOW_LABELS.
Referenced by SurveyTextQuestionGUI\getWorkingForm(), SurveyMetricQuestionGUI\getWorkingForm(), SurveySingleChoiceQuestionGUI\getWorkingForm(), SurveyMultipleChoiceQuestionGUI\getWorkingForm(), and SurveyMatrixQuestionGUI\getWorkingForm().
SurveyQuestionGUI::getQuestionType | ( | ) |
Returns the question type string.
Definition at line 139 of file class.SurveyQuestionGUI.php.
Referenced by setQuestionTabsForClass().
|
abstract |
|
abstractprotected |
|
protected |
Definition at line 227 of file class.SurveyQuestionGUI.php.
References ilObjAdvancedEditing\_getRichTextEditor(), ilObjAdvancedEditing\_getUsedHTMLTags(), addCommandButtons(), addFieldsToEditForm(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ILIAS\Repository\object(), ilFormPropertyGUI\setRequired(), and ilCheckboxInputGUI\setValue().
Referenced by editQuestion(), and saveForm().
|
abstractprotected |
|
protected |
Definition at line 930 of file class.SurveyQuestionGUI.php.
References ilSurveyPhrases\_getAvailablePhrases(), ilSurveyPhrases\_getCategoriesForPhrase(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ilFormPropertyGUI\setRequired().
Referenced by addPhrase(), and addSelectedPhrase().
SurveyQuestionGUI::linkChilds | ( | ) |
Definition at line 846 of file class.SurveyQuestionGUI.php.
References $tabs, ILIAS\Repository\ctrl(), ilLMPageObject\getPageList(), ILIAS\Repository\lng(), and ILIAS\Repository\object().
SurveyQuestionGUI::material | ( | bool | $checkonly = false | ) |
Material tab of the survey questions.
Definition at line 669 of file class.SurveyQuestionGUI.php.
References $data, $errors, $rbacsystem, $tabs, $type, SurveyQuestion\_getInternalLinkHref(), ilTabsGUI\activateTab(), ilRbacSystem\checkAccess(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ILIAS\Repository\object(), ilLegacyFormElementsUtil\prepareFormOutput(), and ilFormPropertyGUI\setRequired().
Referenced by addMaterial().
|
protected |
Definition at line 450 of file class.SurveyQuestionGUI.php.
References $tabs, ilTabsGUI\activateTab(), ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().
|
protected |
Definition at line 144 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\object(), and HTML_Template_IT\setVariable().
Referenced by SurveyTextQuestionGUI\getPrintView(), SurveySingleChoiceQuestionGUI\getPrintView(), SurveyMetricQuestionGUI\getPrintView(), SurveyMultipleChoiceQuestionGUI\getPrintView(), SurveyMatrixQuestionGUI\getPrintView(), SurveyTextQuestionGUI\getWorkingForm(), SurveyMetricQuestionGUI\getWorkingForm(), SurveySingleChoiceQuestionGUI\getWorkingForm(), SurveyMultipleChoiceQuestionGUI\getWorkingForm(), and SurveyMatrixQuestionGUI\getWorkingForm().
SurveyQuestionGUI::preview | ( | ) |
Definition at line 599 of file class.SurveyQuestionGUI.php.
References $panel, $tabs, ilTabsGUI\activateTab(), ilGlobalTemplateInterface\get(), ilPanelGUI\getInstance(), getWorkingForm(), ILIAS\Repository\lng(), ILIAS\Repository\object(), ilGlobalTemplateInterface\parseCurrentBlock(), ilGlobalTemplateInterface\setCurrentBlock(), and ilGlobalTemplateInterface\setVariable().
|
protected |
Redirect to calling survey or to edit form.
Definition at line 488 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\ctrl(), and ilUtil\redirect().
Referenced by cancelSync(), save(), sync(), and syncCopies().
SurveyQuestionGUI::removeMaterial | ( | ) |
Definition at line 805 of file class.SurveyQuestionGUI.php.
References editQuestion().
|
protected |
Definition at line 1098 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 354 of file class.SurveyQuestionGUI.php.
References $ilUser, $user, SurveyQuestion\_isComplete(), SurveyQuestion\_isWriteable(), SurveyQuestion\_questionExists(), ILIAS\Repository\ctrl(), editQuestion(), ILIAS\Repository\lng(), ILIAS\Repository\object(), redirectAfterSaving(), and saveForm().
Referenced by saveReturn(), and saveSync().
|
protected |
Definition at line 330 of file class.SurveyQuestionGUI.php.
References editQuestion(), importEditFormValues(), initEditForm(), and validateEditForm().
Referenced by addPhrase(), save(), and savePhrase().
SurveyQuestionGUI::savePhrase | ( | bool | $a_reload = false | ) |
Creates an output to save the current answers as a phrase.
Definition at line 1025 of file class.SurveyQuestionGUI.php.
References $data, $i, $tabs, $toolbar, $txt, ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and saveForm().
Referenced by confirmSavePhrase().
|
protected |
Definition at line 325 of file class.SurveyQuestionGUI.php.
References save().
|
protected |
Definition at line 320 of file class.SurveyQuestionGUI.php.
References save().
SurveyQuestionGUI::setBackUrl | ( | string | $a_url | ) |
Definition at line 156 of file class.SurveyQuestionGUI.php.
|
abstract |
SurveyQuestionGUI::setQuestionTabsForClass | ( | string | $guiclass | ) |
Definition at line 161 of file class.SurveyQuestionGUI.php.
References $rbacsystem, $tabs, ilRbacSystem\checkAccess(), ILIAS\Repository\ctrl(), getQuestionType(), ILIAS\Repository\lng(), and ILIAS\Repository\object().
Referenced by SurveyMatrixQuestionGUI\setQuestionTabs(), SurveyMultipleChoiceQuestionGUI\setQuestionTabs(), SurveyMetricQuestionGUI\setQuestionTabs(), SurveyTextQuestionGUI\setQuestionTabs(), and SurveySingleChoiceQuestionGUI\setQuestionTabs().
|
protected |
Definition at line 468 of file class.SurveyQuestionGUI.php.
References ILIAS\Repository\lng(), and redirectAfterSaving().
|
protected |
Definition at line 404 of file class.SurveyQuestionGUI.php.
References $access, $id, $lng, $ref_id, ilObject\_getAllReferences(), copySyncForm(), ILIAS\Repository\object(), redirectAfterSaving(), and ilLanguage\txt().
|
protected |
Definition at line 536 of file class.SurveyQuestionGUI.php.
References addFieldsToEditForm(), getPrintView(), and importEditFormValues().
Referenced by saveForm().
|
protected |
Definition at line 34 of file class.SurveyQuestionGUI.php.
Referenced by syncCopies().
|
protected |
Definition at line 40 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 41 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 31 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 39 of file class.SurveyQuestionGUI.php.
Referenced by __construct(), and syncCopies().
|
protected |
Definition at line 43 of file class.SurveyQuestionGUI.php.
SurveyQuestion SurveyQuestionGUI::$object = null |
Definition at line 44 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 42 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 32 of file class.SurveyQuestionGUI.php.
Referenced by material(), and setQuestionTabsForClass().
|
protected |
Definition at line 30 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 37 of file class.SurveyQuestionGUI.php.
Referenced by addMaterial(), addPhrase(), copySyncForm(), editQuestion(), SurveyMatrixQuestionGUI\layout(), linkChilds(), material(), originalSyncForm(), preview(), savePhrase(), and setQuestionTabsForClass().
|
protected |
Definition at line 36 of file class.SurveyQuestionGUI.php.
Referenced by addMaterial(), and savePhrase().
|
protected |
Definition at line 38 of file class.SurveyQuestionGUI.php.
Referenced by __construct().
|
protected |
Definition at line 35 of file class.SurveyQuestionGUI.php.
|
protected |
Definition at line 33 of file class.SurveyQuestionGUI.php.
Referenced by save().