19 declare(strict_types=1);
210 'tst_finish_notification_simple',
211 'tst_finish_notification_advanced',
212 'test_question_set_type_fixed',
213 'tst_title_output_full',
214 'tst_title_output_hide_points',
215 'tst_title_output_no_title',
216 'tst_title_output_only_points',
217 'tst_instant_feedback_trigger_forced',
218 'tst_instant_feedback_trigger_manual',
219 'tst_answer_fixation_none',
220 'tst_answer_fixation_on_instantfb_or_followupqst',
221 'tst_answer_fixation_on_instant_feedback',
222 'tst_answer_fixation_on_followup_question',
223 'tst_highscore_own_table',
224 'tst_highscore_top_table',
225 'tst_highscore_all_tables',
226 'tst_results_access_setting',
227 'tst_results_access_finished',
228 'tst_results_access_always',
229 'tst_results_access_setting',
230 'tst_results_access_passed',
231 'tst_count_partial_solutions',
232 'tst_count_correct_solutions',
233 'tst_score_cut_question',
234 'tst_score_cut_test',
235 'tst_pass_last_pass',
236 'tst_pass_best_pass',
237 'tst_inp_quest_amount_cfg_mode_pool',
238 'tst_imap_qst_mode_mc',
239 'tst_imap_qst_mode_sc',
240 'option_label_right_wrong',
241 'option_label_plus_minus',
242 'option_label_applicable_or_not',
243 'option_label_adequate_or_not',
244 'option_label_custom',
245 'qpl_qst_inp_matching_mode_one_on_one',
246 'qpl_qst_inp_matching_mode_all_on_all',
247 'essay_scoring_mode_without_keywords',
248 'essay_scoring_mode_keyword_relation_any',
249 'essay_scoring_mode_keyword_relation_all',
250 'essay_scoring_mode_keyword_relation_one',
251 'qst_nested_nested_answers_off',
252 'qst_nested_nested_answers_on',
253 'oq_btn_use_order_pictures',
254 'oq_btn_use_order_terms',
266 private readonly \Mustache_Engine $mustache,
272 $lng->loadLanguageModule(
'assessment');
273 $lng->loadLanguageModule(
'crs');
278 array $additional_info,
288 return $this->ui_factory->listing()->descriptive(
292 array_keys($additional_info)
295 fn(
string $k):
string => $this->
parseValue($k, $additional_info[$k], $environment),
296 array_keys($additional_info)
303 array $additional_info,
309 fn(
string $k) =>
"{$this->getCorrectedTranslationForKey($k)}: {$this->parseValue($k, $additional_info[$k] ?? '', $environment)}",
310 array_keys($additional_info)
317 return $bool ? self::TAG_TRUE : self::TAG_FALSE;
322 return $bool ? self::TAG_ENABLED : self::TAG_DISABLED;
327 return $bool ? self::TAG_CHECKED : self::TAG_UNCHECKED;
332 return self::TAG_NONE;
337 return "{{ {$lang_var} }}";
343 if (array_key_exists($key, self::LEGACY_TAGS)) {
344 $lang_var = self::LEGACY_TAGS[$key];
347 return $this->
lng->exists($lang_var) ? $this->
lng->txt($lang_var) : $key;
352 string|
int|
float|array $value,
357 return \ilUserUtil::getNamePresentation(
364 case self::KEY_USERS:
366 case self::KEY_QUESTION_TYPE:
367 return $this->
lng->txt($value);
368 case self::KEY_QUESTIONS:
372 fn(
int $usr):
string => $this->questions_repo
373 ->getForQuestionId($usr)?->
getTitle() ?? $this->
lng->txt(
'deleted'),
377 case self::KEY_QUESTION_ID:
378 if (is_int($value)) {
379 return $this->
refinery->encode()->htmlSpecialCharsAsEntities()->transform(
380 $this->questions_repo->getForQuestionId($value)?->getTitle() ?? $this->
lng->txt(
'deleted')
407 string|
int|
float|array $value,
411 || is_float($value)) {
412 return (
string) $value;
414 if (is_array($value)) {
418 return $this->
lng->txt(
'none');
420 if (strpos($value,
'+0000') !==
false 421 && ($date = \DateTimeImmutable::createFromFormat(self::DATE_STORAGE_FORMAT, $value)) !==
false) {
423 ->setTimezone($environment[
'timezone'])
424 ->format($environment[
'date_format']);
426 return $this->mustache->render(
427 $this->
refinery->string()->stripTags()->transform($value),
436 function (
$c, $k) use ($value, $environment):
string {
444 return "{$c}{$label}: {$this->parseValue($k, $value[$k], $environment)}";
452 return array_combine(
455 fn(
string $v):
string => $this->
lng->txt($v),
459 array_keys(self::LEGACY_TAGS),
460 function (array
$c,
string $k): array {
461 $c[$k] = $this->
lng->txt(self::LEGACY_TAGS[$k]);
static getNamePresentation( $a_user_id, bool $a_user_image=false, bool $a_profile_link=false, string $a_profile_back_link='', bool $a_force_first_lastname=false, bool $a_omit_login=false, bool $a_sortable=true, bool $a_return_data_array=false, $a_ctrl_path='ilpublicuserprofilegui')
Default behaviour is:
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...