19 declare(strict_types=1);
47 $this->
setId(
'tst_participants_' . $parent_obj->
getTestObj()->getRefId());
50 $this->is_score_last_pass = $parent_obj->
getTestObj()->getScoreSettings()
53 $this->
setStyle(
'table',
'fullwidth');
58 $this->
setRowTemplate(
"tpl.il_as_tst_scorings_row.html",
"Modules/Test");
101 return in_array($a_field, array(
102 'scored_pass',
'answered_questions',
'reached_points',
'percent_result' 126 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_scored_pass"),
'scored_pass');
127 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_pass_finished"),
'scored_pass_finished_timestamp');
129 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_answered_questions"),
'answered_questions');
130 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_reached_points"),
'reached_points');
131 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_percent_result"),
'percent_result');
133 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_passed_status"),
'passed_status');
134 $this->
addColumn($this->
lng->txt(
"tst_tbl_col_final_mark"),
'final_mark');
146 $this->
addMultiCommand(
'showDetailedResults', $this->
lng->txt(
'show_detailed_results'));
150 $this->
addMultiCommand(
'deleteSingleUserResults', $this->
lng->txt(
'delete_user_data'));
157 $this->tpl->setCurrentBlock(
'checkbox_column');
158 $this->tpl->setVariable(
"CHB_ROW_KEY", $a_set[
'active_id']);
159 $this->tpl->parseCurrentBlock();
163 $this->tpl->setCurrentBlock(
'actions_column');
165 $this->tpl->parseCurrentBlock();
168 $this->tpl->setVariable(
"ROW_KEY", $a_set[
'active_id']);
169 $this->tpl->setVariable(
"LOGIN", $a_set[
'login']);
170 $this->tpl->setVariable(
"FULLNAME", $a_set[
'name']);
185 $this->
ctrl->setParameterByClass(
'iltestevaluationgui',
'active_id', $data[
'active_id']);
189 $resultsHref = $this->
ctrl->getLinkTargetByClass([ilTestResultsGUI::class, ilParticipantsTestResultsGUI::class, ilTestEvaluationGUI::class],
'outParticipantsResultsOverview');
190 $actions[] = $this->ui_factory->link()->standard($this->
lng->txt(
'tst_show_results'), $resultsHref);
192 $dropdown = $this->ui_factory->dropdown()->standard($actions);
193 return $this->ui_renderer->render($dropdown);
220 if ($data[
'has_unfinished_passes'] && $this->is_score_last_pass) {
224 if ($data[
'passed_status']) {
243 $icon = $this->ui_factory->symbol()->icon()->custom(
247 return $this->ui_renderer->render(
$icon);
257 return $this->
lng->txt(
'pass') .
' ' . ($data[
'scored_pass'] + 1);
262 if (isset($data[
'scored_pass_finished_timestamp'])) {
271 $this->
lng->txt(
'tst_answered_questions_of_total'),
272 $data[
'answered_questions'],
273 $data[
'total_questions']
280 $this->
lng->txt(
'tst_reached_points_of_max'),
281 $data[
'reached_points'],
288 if ($data[
'has_unfinished_passes'] && $this->is_score_last_pass) {
291 return $data[
'final_mark'];
296 return sprintf(
'%0.2f %%', $data[
'percent_result'] * 100);
buildImageIcon(string $icon_name, string $label)
bool $manageResultsCommandsEnabled
enable(string $a_module_name)
numericOrdering(string $a_field)
isAccessResultsCommandsEnabled()
ilParticipantsTestResultsGUI: ilTestEvaluationGUI ilParticipantsTestResultsGUI: ilAssQuestionPageGUI...
setFormAction(string $a_form_action, bool $a_multipart=false)
setAccessResultsCommandsEnabled(bool $accessResultsCommandsEnabled)
setSelectAllCheckbox(string $a_select_all_checkbox, bool $a_select_all_on_top=false)
static getImagePath(string $img, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
static formatDate(ilDateTime $date, bool $a_skip_day=false, bool $a_include_wd=false, bool $include_seconds=false)
buildPercentResultString(array $data)
buildActionsMenu(array $data)
isMultiRowSelectionRequired()
bool $accessResultsCommandsEnabled
setFormName(string $a_name="")
isManageResultsCommandsEnabled()
setStyle(string $a_element, string $a_style)
setShowRowsSelector(bool $a_value)
Toggle rows-per-page selector.
setDefaultOrderField(string $a_defaultorderfield)
buildMarkString(array $data)
setManageResultsCommandsEnabled(bool $manageResultsCommandsEnabled)
buildAnsweredQuestionsString(array $data)
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
isActionsColumnRequired()
setDefaultOrderDirection(string $a_defaultorderdirection)
setAnonymity(bool $anonymity)
__construct(ilParticipantsTestResultsGUI $parent_obj, string $parent_cmd, private UIFactory $ui_factory, private UIRenderer $ui_renderer)
buildScoredPassString(array $data)
buildFormattedAccessDate(array $data)
buildScoredPassFinishedString(array $data)
addColumn(string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)
addMultiCommand(string $a_cmd, string $a_text)
buildReachedPointsString(array $data)
buildPassedStatusString(array $data)