12 include_once(
'Services/Table/classes/class.ilTable2GUI.php');
54 $this->lng = $DIC[
'lng'];
55 $this->ctrl = $DIC[
'ilCtrl'];
56 $this->
user = $DIC[
'ilUser'];
57 $this->rbacsystem = $DIC[
'rbacsystem'];
59 $this->lng->loadLanguageModule(
'crs');
60 $this->lng->loadLanguageModule(
'buddysystem');
65 include_once
"Services/Mail/classes/class.ilMail.php";
67 $this->mailing_allowed = $this->rbacsystem->checkAccess(
'internal_mail',$mail->getMailObjectReferenceId());
74 $mode[
"short"] =
"crs";
75 $mode[
"long"] =
"course";
76 $mode[
"checkbox"] =
"search_crs";
77 $mode[
"tableprefix"] =
"crstable";
78 $mode[
"lng_mail"] = $this->lng->txt(
"mail_my_courses");
79 $mode[
"view"] =
"mycourses";
82 else if ($type ==
"grp")
84 $mode[
"short"] =
"grp";
85 $mode[
"long"] =
"group";
86 $mode[
"checkbox"] =
"search_grp";
87 $mode[
"tableprefix"] =
"grptable";
88 $mode[
"lng_mail"] = $this->lng->txt(
"mail_my_groups");
89 $mode[
"view"] =
"mygroups";
94 parent::__construct($a_parent_obj);
97 $this->parentObject = $a_parent_obj;
101 $this->ctrl->setParameter($a_parent_obj,
'view',
$mode[
'view']);
102 if (
$_GET[
'ref'] !=
'')
103 $this->ctrl->setParameter($a_parent_obj,
'ref',
$_GET[
'ref']);
105 $this->ctrl->setParameter($a_parent_obj, $mode[
"checkbox"], implode(
',',
$_POST[$mode[
"checkbox"]]));
107 $this->
setFormAction($this->ctrl->getFormAction($a_parent_obj));
108 $this->ctrl->clearParameters($a_parent_obj);
111 $this->
setRowTemplate(
'tpl.mail_search_courses_row.html',
'Services/Contact');
117 $this->
addColumn($mode[
"lng_mail"],
'CRS_NAME',
'30%');
118 $this->
addColumn($this->lng->txt(
'path'),
'CRS_PATH',
'30%');
119 $this->
addColumn($this->lng->txt(
'crs_count_members'),
'CRS_NO_MEMBERS',
'20%');
120 $this->
addColumn($this->lng->txt(
'actions'),
'',
'19%');
124 if ($this->mailing_allowed)
129 $this->lng->loadLanguageModule(
"wsp");
130 $this->
addMultiCommand(
'share',$this->lng->txt(
'wsp_share_with_members'));
132 $this->
addMultiCommand(
'showMembers',$this->lng->txt(
'mail_list_members'));
134 if (
$_GET[
'ref'] ==
'mail')
147 if ($a_set[
'hidden_members'])
149 $this->tpl->setCurrentBlock(
'caption_asterisk');
150 $this->tpl->touchBlock(
'caption_asterisk');
151 $this->tpl->parseCurrentBlock();
153 foreach ($a_set as $key => $value)
155 $this->tpl->setVariable(strtoupper($key), $value);
157 $this->tpl->setVariable(
'SHORT', $this->mode[
"short"]);
162 if(
$column ==
'CRS_NO_MEMBERS')
return true;
addCommandButton($a_cmd, $a_text, $a_onclick='', $a_id="", $a_class=null)
Add Command button.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
This class handles base functions for mail handling.
__construct($a_parent_obj, $type='crs', $context='mail')
Constructor.
addMultiCommand($a_cmd, $a_text)
Add Command button.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
Create styles array
The data for the language used.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
setShowRowsSelector($a_value)
Toggle rows-per-page selector.
setSelectAllCheckbox($a_select_all_checkbox)
Set the name of the checkbox that should be toggled with a select all button.
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.