4 require_once
'Services/Table/classes/class.ilTable2GUI.php';
5 require_once
'Services/Contact/BuddySystem/classes/class.ilBuddyList.php';
6 require_once
'Services/Utilities/classes/class.ilStr.php';
7 require_once
'Services/Contact/BuddySystem/classes/class.ilBuddySystem.php';
37 $this->
setId($type.
'table_members');
38 parent::__construct($a_parent_obj,
'showMembers');
41 if($this->context ==
'mail')
44 include_once
"Services/Mail/classes/class.ilMail.php";
46 $this->mailing_allowed = $rbacsystem->checkAccess(
'internal_mail',$mail->getMailObjectReferenceId());
49 $lng->loadLanguageModule(
'crs');
50 $this->parentObject = $a_parent_obj;
54 $mode[
"checkbox"] =
'search_crs';
55 $mode[
"short"] =
'crs';
56 $mode[
"long"] =
'course';
57 $mode[
"lng_type"] = $lng->txt(
'course');
58 $mode[
"view"] =
"crs_members";
60 else if ($type ==
'grp')
62 $mode[
"checkbox"] =
'search_grp';
63 $mode[
"short"] =
'grp';
64 $mode[
"long"] =
'group';
65 $mode[
"lng_type"] = $lng->txt(
'group');
66 $mode[
"view"] =
"grp_members";
68 $this->
setTitle($lng->txt(
'members'));
70 $ilCtrl->setParameter($a_parent_obj,
'view',
$mode[
'view']);
71 if (
$_GET[
'ref'] !=
'')
72 $ilCtrl->setParameter($a_parent_obj,
'ref',
$_GET[
'ref']);
74 $ilCtrl->setParameter($a_parent_obj, $mode[
"checkbox"], implode(
',',
$_POST[$mode[
"checkbox"]]));
77 $ilCtrl->clearParameters($a_parent_obj);
79 $this->
setRowTemplate(
'tpl.mail_search_courses_members_row.html',
'Services/Contact');
83 $this->
addColumn($lng->txt(
'login'),
'members_login',
'22%');
84 $this->
addColumn($lng->txt(
'name'),
'members_name',
'22%');
85 $this->
addColumn($lng->txt($mode[
'long']),
'members_crs_grp',
'22%');
88 $this->
addColumn($lng->txt(
'buddy_tbl_filter_state'),
'status',
'23%');
90 $this->
addColumn($lng->txt(
'actions'),
'',
'10%');
92 if($this->context ==
"mail")
94 if($this->mailing_allowed)
103 $lng->loadLanguageModule(
"wsp");
106 $lng->loadLanguageModule(
'buddysystem');
118 public function fillRow($a_set)
126 require_once
'Services/UIComponent/AdvancedSelectionList/classes/class.ilAdvancedSelectionListGUI.php';
128 $current_selection_list->setListTitle($this->lng->txt(
"actions"));
129 $current_selection_list->setId(
"act_".md5($a_set[
'members_id'].
'::'.$a_set[
'search_' . $this->mode[
'short']]));
131 $ilCtrl->setParameter($this->parentObject,
'search_members', $a_set[
'members_id']);
132 $ilCtrl->setParameter($this->parentObject,
'search_' . $this->mode[
'short'],
133 is_array(
$_REQUEST[
'search_' . $this->mode[
'short']]) ?
134 implode(
',', array_filter(array_map(
'intval',
$_REQUEST[
'search_' . $this->mode[
'short']]))) :
135 (
int)
$_REQUEST[
'search_' . $this->mode[
'short']]
137 $ilCtrl->setParameter($this->parentObject,
'view', $this->mode[
'view']);
140 if($this->context ==
"mail")
142 if($this->mailing_allowed)
144 $current_selection_list->addItem($this->lng->txt(
"mail_member"),
'', $ilCtrl->getLinkTarget($this->parentObject,
"mail"));
149 $current_selection_list->addItem($this->lng->txt(
"wsp_share_with_members"),
'', $ilCtrl->getLinkTarget($this->parentObject,
"share"));
154 $relation = ilBuddyList::getInstanceByGlobalUser()->getRelationByUserId($a_set[
'members_id']);
156 $a_set[
'members_id'] != $ilUser->getId() &&
157 $relation->isUnlinked() &&
161 $ilCtrl->setParameterByClass(
'ilBuddySystemGUI',
'user_id', $a_set[
'members_id']);
162 $current_selection_list->addItem($this->lng->txt(
'buddy_bs_btn_txt_unlinked_a'),
'', $ilCtrl->getLinkTargetByClass(
'ilBuddySystemGUI',
'request'));
166 if($current_selection_list->getItems())
168 $action_html = $current_selection_list->getHTML();
170 $this->tpl->setVariable(strtoupper(
'CURRENT_ACTION_LIST'), $action_html);
172 foreach($a_set as $key => $value)
174 $this->tpl->setVariable(strtoupper($key), $value);
addCommandButton($a_cmd, $a_text, $a_onclick='', $a_id="", $a_class=null)
Add Command button.
__construct($a_parent_obj, $type='crs', $context='mail')
Constructor.
_lookupPref($a_usr_id, $a_keyword)
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
Class Mail this class handles base functions for mail handling.
addMultiCommand($a_cmd, $a_text)
Add Command button.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
User interface class for advanced drop-down selection lists.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
fillRow($a_set)
Standard Version of Fill Row.
if($_REQUEST['ilias_path']) define('ILIAS_HTTP_PATH' $_REQUEST['ilias_path']
setSelectAllCheckbox($a_select_all_checkbox)
Set the name of the checkbox that should be toggled with a select all button.
static yn2tf($a_yn)
convert "y"/"n" to true/false
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.