ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.UIModifier.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
25
31{
32 public function getSurveySettingsResults(
33 \ilObjSurvey $survey,
34 InternalGUIService $ui_service
35 ): array {
36 $items = [];
37 $lng = $ui_service->lng();
38
39 //check the names of these vars
40 $evaluation_access = new \ilRadioGroupInputGUI($lng->txt('evaluation_access'), "self_eval_res");
41 $evaluation_access->setValue((string) $survey->getSelfEvaluationResults());
42
43 $option = new \ilRadioOption($lng->txt("svy_self_ev_access_results_none"), (string) \ilObjSurvey::RESULTS_SELF_EVAL_NONE);
44 $evaluation_access->addOption($option);
45
46 $option = new \ilRadioOption($lng->txt("svy_self_ev_access_results_own"), (string) \ilObjSurvey::RESULTS_SELF_EVAL_OWN);
47 $evaluation_access->addOption($option);
48
49 $option = new \ilRadioOption($lng->txt("svy_self_ev_access_results_all"), (string) \ilObjSurvey::RESULTS_SELF_EVAL_ALL);
50 $evaluation_access->addOption($option);
51
52 $items[] = $evaluation_access;
53
54 return $items;
55 }
56
57 public function setValuesFromForm(
58 \ilObjSurvey $survey,
60 ): void {
61 $survey->setSelfEvaluationResults((int) $form->getInput("self_eval_res"));
62 }
63}
setValuesFromForm(\ilObjSurvey $survey, \ilPropertyFormGUI $form)
getSurveySettingsResults(\ilObjSurvey $survey, InternalGUIService $ui_service)
const RESULTS_SELF_EVAL_NONE
const RESULTS_SELF_EVAL_ALL
const RESULTS_SELF_EVAL_OWN
This class represents a property form user interface.
global $lng
Definition: privfeed.php:31