4 include_once
'./Services/Table/classes/class.ilTable2GUI.php';
34 public function __construct($a_parent_obj, $a_parent_cmd, $a_mode, $a_team_id,
ilExAssignment $a_assignment, array $a_member_ids = null, $a_read_only =
false)
38 $this->mode = $a_mode;
39 $this->team_id = $a_team_id;
40 $this->assignment = $a_assignment;
41 $this->member_ids = $a_member_ids;
42 $this->read_only = (bool)$a_read_only;
50 $this->
addColumn($this->lng->txt(
"name"),
"name");
54 $this->
setRowTemplate(
"tpl.exc_team_member_row.html",
"Modules/Exercise");
55 $this->
setFormAction($ilCtrl->getFormAction($a_parent_obj, $a_parent_cmd));
59 if($this->mode == self::MODE_ADD)
61 $this->
setTitle($this->lng->txt(
"exc_team_member_container_add"));
62 $this->
addMultiCommand(
"addTeamMemberContainerAction", $this->lng->txt(
"add"));
66 $this->
setTitle($this->lng->txt(
"exc_team_members"));
67 $this->
addMultiCommand(
"confirmRemoveTeamMember", $this->lng->txt(
"remove"));
79 if($this->mode == self::MODE_ADD)
81 $assigned = $this->assignment->getMembersOfAllTeams();
86 $this->member_ids = $this->assignment->getTeamMembers($this->team_id);
89 include_once
"Services/User/classes/class.ilUserUtil.php";
92 foreach($this->member_ids as $id)
94 if(!in_array($id, $assigned))
96 $data[] = array(
"id" => $id,
111 if(!$this->read_only)
113 $this->tpl->setVariable(
"VAL_ID", $a_set[
"id"]);
115 $this->tpl->setVariable(
"TXT_NAME", $a_set[
"name"]);