3require_once
'Services/Table/classes/class.ilTable2GUI.php';
4require_once
'Modules/IndividualAssessment/classes/Members/class.ilIndividualAssessmentMembersStorageDB.php';
5require_once
'Services/UIComponent/AdvancedSelectionList/classes/class.ilAdvancedSelectionListGUI.php';
6require_once
'Services/Tracking/classes/class.ilLearningProgressBaseGUI.php';
7require_once
'Services/Tracking/classes/class.ilLPStatus.php';
17 public function __construct($a_parent_obj, $a_parent_cmd=
"", $a_template_context=
"")
19 parent::__construct($a_parent_obj, $a_parent_cmd, $a_template_context);
22 $this->ctrl =
$DIC[
'ilCtrl'];
23 $this->lng =
$DIC[
'lng'];
24 $this->viewer_id = (int)
$DIC[
'ilUser']->
getId();
31 $this->
setRowTemplate(
"tpl.members_table_row.html",
"Modules/IndividualAssessment");
32 $this->
setFormAction($this->ctrl->getFormAction($a_parent_obj,
"view"));
34 $this->iass_access = $this->parent_obj->object->accessHandler();
39 $this->
setData(iterator_to_array($a_parent_obj->object->loadVisibleMembers()));
49 $columns = array(
'name' => array(
'name',
"")
50 ,
'login' => array(
'login',
""));
52 $columns[
'grading'] = array(
'lp_status',
"");
53 $columns[
'iass_graded_by'] = array(
'iass_graded_by',
"");
54 $columns[
'iass_changed_by'] = array(
'iass_changed_by',
"");
56 $columns[
'actions'] = array(
null,
"120px");
69 $this->tpl->setCurrentBlock(
'access_warning');
70 $this->tpl->setVariable(
'PARENT_ACCESS', $this->lng->txt(
'usr_account_inactive'));
71 $this->tpl->parseCurrentBlock();
75 $this->tpl->setCurrentBlock(
'grading_columns');
80 if ($a_set[
'finalized'] ===
'0' && $a_set[
'examiner_id'] !==
null) {
89 $this->tpl->setVariable(
"GRADED_BY", $graded_by);
99 $this->tpl->setVariable(
"CHANGED_BY", $changed_by);
100 $this->tpl->parseCurrentBlock();
143 return $this->lng->txt(
'iass_status_pending');
146 return $this->lng->txt(
'iass_status_completed');
149 return $this->lng->txt(
'iass_status_failed');
152 return $this->lng->txt(
'iass_assessment_not_completed');
167 $l->setListTitle($this->lng->txt(
"actions"));
169 $this->ctrl->setParameterByClass(
'ilIndividualAssessmentMemberGUI',
'usr_id', $a_set[
'usr_id']);
174 $target = $this->ctrl->getLinkTargetByClass(
'ilIndividualAssessmentMemberGUI',
'view');
175 $l->addItem($this->lng->txt(
'iass_usr_view'),
'view',
$target);
179 $target = $this->ctrl->getLinkTargetByClass(
'ilIndividualAssessmentMemberGUI',
'edit');
180 $l->addItem($this->lng->txt(
'iass_usr_edit'),
'edit',
$target);
184 $this->ctrl->setParameter($this->parent_obj,
'usr_id', $a_set[
'usr_id']);
185 $target = $this->ctrl->getLinkTarget($this->parent_obj,
'removeUserConfirmation');
186 $this->ctrl->setParameter($this->parent_obj,
'usr_id',
null);
187 $l->addItem($this->lng->txt(
'iass_usr_remove'),
'removeUser',
$target);
191 $target = $this->ctrl->getLinkTargetByClass(
'ilIndividualAssessmentMemberGUI',
'amend');
192 $l->addItem($this->lng->txt(
'iass_usr_amend'),
'amend',
$target);
196 $target = $this->ctrl->getLinkTargetByClass(
'ilIndividualAssessmentMemberGUI',
'downloadAttachment');
197 $l->addItem($this->lng->txt(
'iass_usr_download_attachment'),
'downloadAttachment',
$target);
199 $this->ctrl->setParameterByClass(
'ilIndividualAssessmentMemberGUI',
'usr_id',
null);
200 return $l->getHTML();
212 return $examiner_id === $this->viewer_id || 0 === $examiner_id;
222 return $this->iass_access->mayGradeUser();
233 return $this->iass_access->mayGradeUserById($a_user_id);
243 return $this->iass_access->mayViewUser();
253 return $this->iass_access->mayEditMembers();
263 return $this->iass_access->mayAmendGradeUser();
283 return $this->iass_access->isSystemAdmin();
An exception for terminatinating execution or to throw for unit testing.
User interface class for advanced drop-down selection lists.
@classDescription Date and time handling
getEntryForStatus($a_status)
Get text for lp status.
userMayDownloadAttachment($usr_id)
User may download attachment.
userMayViewGrades()
User may view grades.
getImagetPathForStatus($a_status)
Get image path for lp images.
fillRow($a_set)
Standard Version of Fill Row.Most likely to be overwritten by derived class.
buildActionDropDown($a_set)
Get the action drop down.
visibleColumns()
Get column user should be shown.
userMayEditGradesOf($a_user_id)
User may edit grades of a specific user.
__construct($a_parent_obj, $a_parent_cmd="", $a_template_context="")
ilTable2GUI constructor.
userMayAmendGrades()
User may amend grades.
setWasEditedByViewer($examiner_id)
Check the set was edited by viewing user.
userIsSystemAdmin()
Check whether usr is admin.
userMayEditMembers()
User may amend members records.
userMayEditGrades()
User may edit grades.
const FIELD_CHANGER_LASTNAME
const FIELD_CHANGER_FIRSTNAME
const LP_ASSESSMENT_NOT_COMPLETED
const FIELD_EXAMINER_FIRSTNAME
const FIELD_LEARNING_PROGRESS
const FIELD_EXAMINER_LASTNAME
const LP_STATUS_COMPLETED_NUM
const LP_STATUS_IN_PROGRESS_NUM
const LP_STATUS_FAILED_NUM
const LP_STATUS_NOT_ATTEMPTED
static _getImagePathForStatus($a_status)
Get image path for status.
static _lookupActive($a_usr_id)
Check user account active.
setTopCommands($a_val)
Set top commands (display command buttons on top of table, too)
setEnableHeader($a_enableheader)
Set Enable Header.
setExternalSorting($a_val)
Set external sorting.
setData($a_data)
set table data @access public
setEnableTitle($a_enabletitle)
Set Enable Title.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
addColumn( $a_text, $a_sort_field="", $a_width="", $a_is_checkbox_action_column=false, $a_class="", $a_tooltip="", $a_tooltip_with_html=false)
Add a column to the header.
setExternalSegmentation($a_val)
Set external segmentation.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.