24 include_once(
'Services/Table/classes/class.ilTable2GUI.php');
25 include_once(
'Services/WebServices/ECS/classes/class.ilECSParticipantSettings.php');
62 $this->
addColumn($this->lng->txt(
'ecs_participants'),
'participants',
"35%");
63 $this->
addColumn($this->lng->txt(
'ecs_participants_infos'),
'infos',
"35%");
64 $this->
addColumn($this->lng->txt(
'ecs_tbl_export'),
'export',
'5%');
65 $this->
addColumn($this->lng->txt(
'ecs_tbl_import'),
'import',
'5%');
66 $this->
addColumn($this->lng->txt(
'ecs_tbl_import_type'),
'type',
'10%');
69 $this->
setRowTemplate(
"tpl.participant_row.html",
"Services/WebServices/ECS");
97 $this->tpl->setVariable(
'S_ID', $this->
getServer()->getServerId());
98 $this->tpl->setVariable(
'M_ID', $a_set[
'mid']);
99 $this->tpl->setVariable(
'VAL_ID', $this->
getServer()->getServerId().
'_'.$a_set[
'mid']);
100 $this->tpl->setVariable(
'VAL_ORG', (
string) $a_set[
'org']);
101 $this->tpl->setVariable(
'VAL_CHECKED',$a_set[
'checked'] ?
'checked="checked"' :
'');
102 $this->tpl->setVariable(
'VAL_TITLE',$a_set[
'participants']);
103 $this->tpl->setVariable(
'VAL_DESC',$a_set[
'description']);
104 $this->tpl->setVariable(
'VAL_EMAIL',$a_set[
'email']);
105 $this->tpl->setVariable(
'VAL_DNS',$a_set[
'dns']);
106 $this->tpl->setVariable(
'VAL_ABR',$a_set[
'abr']);
107 $this->tpl->setVariable(
'TXT_EMAIL',$this->lng->txt(
'ecs_email'));
108 $this->tpl->setVariable(
'TXT_DNS',$this->lng->txt(
'ecs_dns'));
109 $this->tpl->setVariable(
'TXT_ABR',$this->lng->txt(
'ecs_abr'));
110 $this->tpl->setVariable(
'TXT_ID',$this->lng->txt(
'ecs_unique_id'));
111 $this->tpl->setVariable(
'TXT_ORG', $this->lng->txt(
'organization'));
113 include_once
'./Services/WebServices/ECS/classes/class.ilECSParticipantSetting.php';
117 if($part->isExportEnabled())
119 foreach($part->getExportTypes() as $obj_type)
121 $this->tpl->setCurrentBlock(
'obj_erow');
122 $this->tpl->setVariable(
'TXT_OBJ_EINFO',$this->lng->txt(
'objs_'.$obj_type));
123 $this->tpl->parseCurrentBlock();
128 $this->lng->loadLanguageModule(
'administration');
129 $this->tpl->setVariable(
'TXT_OBJ_EINFO',$this->lng->txt(
'disabled'));
132 if($part->isImportEnabled())
134 foreach($part->getImportTypes() as $obj_type)
136 $this->tpl->setCurrentBlock(
'obj_irow');
137 $this->tpl->setVariable(
'TXT_OBJ_IINFO',$this->lng->txt(
'objs_'.$obj_type));
138 $this->tpl->parseCurrentBlock();
143 $this->lng->loadLanguageModule(
'administration');
144 $this->tpl->setVariable(
'TXT_OBJ_IINFO',$this->lng->txt(
'disabled'));
148 $part->getImportType(),
149 'import_type['.$this->getServer()->getServerId().
']['.$a_set[
'mid'].
']',
158 $this->tpl->setVariable(
'IMPORT_SEL', $sel);
160 include_once
'./Services/UIComponent/AdvancedSelectionList/classes/class.ilAdvancedSelectionListGUI.php';
162 $list->setItemLinkClass(
'small');
163 $list->setSelectionHeaderClass(
'small');
164 $list->setId(
'actl_'.$a_set[
'server_id'].
'_'.$a_set[
'mid']);
165 $list->setListTitle($this->lng->txt(
'actions'));
170 $this->lng->txt(
'edit'),
172 $ilCtrl->getLinkTargetByClass(
'ilecsparticipantsettingsgui',
'settings')
175 switch($part->getImportType())
186 $this->lng->txt(
'ecs_crs_alloc_set'),
188 $ilCtrl->getLinkTargetByClass(
'ilecsmappingsettingsgui',
'cStart')
198 $this->lng->txt(
'ecs_dir_alloc_set'),
200 $ilCtrl->getLinkTargetByClass(
'ilecsmappingsettingsgui',
'dStart')
203 $this->lng->txt(
'ecs_crs_alloc_set'),
205 $ilCtrl->getLinkTargetByClass(
'ilecsmappingsettingsgui',
'cStart')
209 $this->tpl->setVariable(
'ACTIONS',$list->getHTML());
219 public function parse($a_participants)
221 foreach($a_participants as $participant)
223 $tmp_arr[
'mid'] = $participant->getMID();
224 $tmp_arr[
'participants'] = $participant->getParticipantName();
225 $tmp_arr[
'description'] = $participant->getDescription();
226 $tmp_arr[
'email'] = $participant->getEmail();
227 $tmp_arr[
'dns'] = $participant->getDNS();
231 $tmp_arr[
'abr'] = $participant->getOrganisation()->getAbbreviation();
232 $tmp_arr[
'org'] = $participant->getOrganisation()->getName();
237 $this->
setData($def ? $def : array());