ILIAS  release_5-0 Revision 5.0.0-1144-gc4397b1f870
ilObjMailGUI Class Reference

Class ilObjMailGUI for admin panel. More...

+ Inheritance diagram for ilObjMailGUI:
+ Collaboration diagram for ilObjMailGUI:

Public Member Functions

 __construct ($a_data, $a_id, $a_call_by_reference)
 Constructor @access public. More...
 
 viewObject ()
 list childs of current object More...
 
 saveObject ()
 save object More...
 
 importObject ()
 
 performImportObject ()
 
 uploadObject ()
 
 __initFileObject ()
 
 __initParserObject ($a_xml, $a_mode)
 
executeCommand ()
 execute command More...
 
 getAdminTabs (&$tabs_gui)
 administration tabs show only permissions and trash folder More...
 
 getTabs (&$tabs_gui)
 get tabs @access public More...
 
- Public Member Functions inherited from ilObjectGUI
 ilObjectGUI ($a_data, $a_id=0, $a_call_by_reference=true, $a_prepare_output=true)
 Constructor @access public. More...
 
executeCommand ()
 execute command More...
 
 withReferences ()
 determines wether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 getAdminTabs (&$tabs_gui)
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelDeleteObject ()
 cancel deletion of object More...
 
 cancelObject ($in_rep=false)
 cancel action and go back to previous page @access public More...
 
 createObject ()
 create new object form More...
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 save object More...
 
 editObject ()
 edit object More...
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction ($a_cmd, $a_formaction="")
 get form action for command (command is method name without "Object", e.g. More...
 
 isVisible ($a_ref_id, $a_type)
 
 viewObject ()
 list childs of current object More...
 
 deleteObject ($a_error=false)
 Display deletion confirmation screen. More...
 
 cloneAllObject ()
 Clone single (not container object) Method is overwritten in ilContainerGUI. More...
 

Static Public Member Functions

static _goto ($a_target)
 goto target group More...
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot ($a_raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode ($a_ref_id, $a_cmd="frameset")
 Goto repository root. More...
 

Private Member Functions

 initForm ()
 
 setDefaultValues ()
 

Additional Inherited Members

- Data Fields inherited from ilObjectGUI
const COPY_WIZARD_NEEDS_PAGE = 1
 
 $ilias
 
 $objDefinition
 
 $tpl
 
 $tree
 
 $lng
 
 $data
 
 $object
 
 $ref_id
 
 $obj_id
 
 $maxcount
 
 $formaction
 
 $return_location
 
 $target_frame
 
 $tab_target_script
 
 $actions
 
 $sub_objects
 
 $omit_locator = false
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 
- Protected Member Functions inherited from ilObjectGUI
 assignObject ()
 
 prepareOutput ()
 prepare output More...
 
 setTitleAndDescription ()
 called by prepare output More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction ($a_list_gui)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 showMountWebfolderIcon ()
 
 setTabs ()
 set admin tabs @access public More...
 
 setAdminTabs ()
 set admin tabs @access public More...
 
 setLocator ()
 set Locator More...
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator ($a_omit=true)
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 getCreationFormsHTML (array $a_forms)
 Get HTML for creation forms (accordion) More...
 
 initCreateForm ($a_new_type)
 Init object creation form. More...
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 Show didactic template types. More...
 
 addDidacticTemplateOptions (array &$a_options)
 Add custom templates. More...
 
 getDidacticTemplateVar ($a_type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
 afterSave (ilObject $a_new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 Init object edit form. More...
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 Get values for edit form. More...
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $a_form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $a_form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 initImportForm ($a_new_type)
 Init object import form. More...
 
 importFileObject ($parent_id=null)
 Import. More...
 
 afterImport (ilObject $a_new_object)
 Post (successful) object import hook. More...
 
 setFormAction ($a_cmd, $a_formaction)
 set specific form action for command More...
 
 getReturnLocation ($a_cmd, $a_location="")
 get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 getTemplateFile ($a_cmd, $a_type="")
 get a template blockfile format: tpl. More...
 
 getTitlesByRefId ($a_ref_ids)
 get Titles of objects this method is used for error messages in methods cut/copy/paste More...
 
 getTabs (&$tabs_gui)
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 setColumnSettings ($column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission. More...
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 handleAutoRating (ilObject $a_new_obj)
 Activate rating automatically if parent container setting. More...
 

Detailed Description

Class ilObjMailGUI for admin panel.

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om $Id$

@ilCtrl_Calls ilObjMailGUI: ilPermissionGUI

Definition at line 17 of file class.ilObjMailGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilObjMailGUI::__construct (   $a_data,
  $a_id,
  $a_call_by_reference 
)

Constructor @access public.

Definition at line 23 of file class.ilObjMailGUI.php.

24 {
25 $this->type = 'mail';
26 parent::__construct($a_data,$a_id,$a_call_by_reference, false);
27
28 $this->lng->loadLanguageModule('mail');
29 }

Member Function Documentation

◆ __initFileObject()

ilObjMailGUI::__initFileObject ( )

Definition at line 271 of file class.ilObjMailGUI.php.

272 {
273 include_once "./Services/Mail/classes/class.ilFileDataImportMail.php";
274
275 $this->file_obj =& new ilFileDataImportMail();
276
277 return true;
278 }
This class handles all operations on files for the exercise object.

Referenced by importObject(), performImportObject(), and uploadObject().

+ Here is the caller graph for this function:

◆ __initParserObject()

ilObjMailGUI::__initParserObject (   $a_xml,
  $a_mode 
)

Definition at line 279 of file class.ilObjMailGUI.php.

280 {
281 include_once "Services/Mail/classes/class.ilMailImportParser.php";
282
283 if(!$a_xml)
284 {
285 return false;
286 }
287
288 $this->parser_obj =& new ilMailImportParser($a_xml,$a_mode);
289
290 return true;
291 }

Referenced by performImportObject(), and uploadObject().

+ Here is the caller graph for this function:

◆ _goto()

static ilObjMailGUI::_goto (   $a_target)
static

goto target group

Definition at line 350 of file class.ilObjMailGUI.php.

351 {
352 global $ilAccess, $ilErr, $lng, $rbacsystem;
353
354 require_once 'Services/Mail/classes/class.ilMail.php';
355 $mail = new ilMail($_SESSION["AccountId"]);
356 if($rbacsystem->checkAccess('internal_mail', $mail->getMailObjectReferenceId()))
357 {
358 ilUtil::redirect("ilias.php?baseClass=ilMailGUI");
359 exit;
360 }
361 else
362 {
363 if ($ilAccess->checkAccess("read", "", ROOT_FOLDER_ID))
364 {
365 $_GET["cmd"] = "frameset";
366 $_GET["target"] = "";
367 $_GET["ref_id"] = ROOT_FOLDER_ID;
368 $_GET["baseClass"] = "ilRepositoryGUI";
369 ilUtil::sendFailure(sprintf($lng->txt("msg_no_perm_read_item"),
371 include("ilias.php");
372 exit;
373 }
374 }
375 $ilErr->raiseError($lng->txt("msg_no_perm_read"), $ilErr->FATAL);
376 }
$_GET["client_id"]
Class Mail this class handles base functions for mail handling.
static _lookupObjId($a_id)
static _lookupTitle($a_id)
lookup object title
static redirect($a_script)
http redirect to other script
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
< a tabindex="-1" style="border-style: none;" href="#" title="Refresh Image" onclick="document.getElementById('siimage').src = './securimage_show.php?sid=' + Math.random(); this.blur(); return false">< img src="./images/refresh.png" alt="Reload Image" height="32" width="32" onclick="this.blur()" align="bottom" border="0"/></a >< br/>< strong > Enter Code *if($_SERVER['REQUEST_METHOD']=='POST' &&@ $_POST['do']=='contact') $_SESSION['ctform']['success']
exit
Definition: login.php:54

References $_GET, $_SESSION, $ilErr, ilObjectGUI\$lng, ilObject\_lookupObjId(), ilObject\_lookupTitle(), exit, ilUtil\redirect(), and ilUtil\sendFailure().

+ Here is the call graph for this function:

◆ executeCommand()

& ilObjMailGUI::executeCommand ( )

execute command

Reimplemented from ilObjectGUI.

Definition at line 293 of file class.ilObjMailGUI.php.

294 {
295 $next_class = $this->ctrl->getNextClass($this);
296 $cmd = $this->ctrl->getCmd();
297 $this->prepareOutput();
298
299 switch($next_class)
300 {
301 case 'ilpermissiongui':
302 include_once("Services/AccessControl/classes/class.ilPermissionGUI.php");
303 $perm_gui =& new ilPermissionGUI($this);
304 $ret =& $this->ctrl->forwardCommand($perm_gui);
305 break;
306
307 default:
308 if(!$cmd)
309 {
310 $cmd = "view";
311 }
312 $cmd .= "Object";
313 $this->$cmd();
314
315 break;
316 }
317 return true;
318 }
prepareOutput()
prepare output
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
$cmd
Definition: sahs_server.php:35

References $cmd, $ret, and ilObjectGUI\prepareOutput().

+ Here is the call graph for this function:

◆ getAdminTabs()

ilObjMailGUI::getAdminTabs ( $tabs_gui)

administration tabs show only permissions and trash folder

Reimplemented from ilObjectGUI.

Definition at line 320 of file class.ilObjMailGUI.php.

321 {
322 $this->getTabs($tabs_gui);
323 }
getTabs(&$tabs_gui)
get tabs @access public

References getTabs().

+ Here is the call graph for this function:

◆ getTabs()

ilObjMailGUI::getTabs ( $tabs_gui)

get tabs @access public

Parameters
objecttabs gui object

Reimplemented from ilObjectGUI.

Definition at line 330 of file class.ilObjMailGUI.php.

331 {
332 global $rbacsystem;
333
334 if ($rbacsystem->checkAccess("visible,read",$this->object->getRefId()))
335 {
336 $tabs_gui->addTarget("settings",
337 $this->ctrl->getLinkTarget($this, "view"), array("view", 'save', ""), "", "");
338 }
339
340 if ($rbacsystem->checkAccess('edit_permission',$this->object->getRefId()))
341 {
342 $tabs_gui->addTarget("perm_settings",
343 $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilpermissiongui'), "perm"), array("perm","info","owner"), 'ilpermissiongui');
344 }
345 }

Referenced by getAdminTabs().

+ Here is the caller graph for this function:

◆ importObject()

ilObjMailGUI::importObject ( )

Definition at line 176 of file class.ilObjMailGUI.php.

177 {
178 global $rbacsystem,$lng;
179
180 if (!$rbacsystem->checkAccess('write',$this->object->getRefId()))
181 {
182 $this->ilias->raiseError($this->lng->txt("msg_no_perm_write"),$this->ilias->error_obj->WARNING);
183 }
184 $this->tpl->addBlockFile("ADM_CONTENT", "adm_content", "tpl.mail_import.html", "Services/Mail");
185
186 // GET ALREADY CREATED UPLOADED XML FILE
187 $this->__initFileObject();
188 if($this->file_obj->findXMLFile())
189 {
190 $this->tpl->setVariable("TXT_IMPORTED_FILE",$lng->txt("checked_files"));
191 $this->tpl->setVariable("XML_FILE",basename($this->file_obj->getXMLFile()));
192
193 $this->tpl->setVariable("BTN_IMPORT",$this->lng->txt("import"));
194 }
195
196 $this->tpl->setVariable("FORMACTION",
197 $this->ctrl->getFormAction($this));
198 $this->tpl->setVariable("TXT_IMPORT_MAIL",$this->lng->txt("table_mail_import"));
199 $this->tpl->setVariable("TXT_IMPORT_FILE",$this->lng->txt("mail_import_file"));
200 $this->tpl->setVariable("BTN_CANCEL",$this->lng->txt("cancel"));
201 $this->tpl->setVariable("BTN_UPLOAD",$this->lng->txt("upload"));
202
203 return true;
204 }
redirection script todo: (a better solution should control the processing via a xml file)

References ilObjectGUI\$lng, and __initFileObject().

+ Here is the call graph for this function:

◆ initForm()

ilObjMailGUI::initForm ( )
private

Definition at line 45 of file class.ilObjMailGUI.php.

46 {
47 include_once 'Services/Form/classes/class.ilPropertyFormGUI.php';
48 $this->form = new ilPropertyFormGUI();
49
50 $this->form->setFormAction($this->ctrl->getFormAction($this, 'save'));
51 $this->form->setTitle($this->lng->txt('general_settings'));
52
53 // Subject prefix
54 $pre = new ilTextInputGUI($this->lng->txt('mail_subject_prefix'),'mail_subject_prefix');
55 $pre->setSize(12);
56 $pre->setMaxLength(32);
57 $pre->setInfo($this->lng->txt('mail_subject_prefix_info'));
58 $this->form->addItem($pre);
59
60 // incoming type
61 include_once 'Services/Mail/classes/class.ilMailOptions.php';
62 $options = array(
63 IL_MAIL_LOCAL => $this->lng->txt('mail_incoming_local'),
64 IL_MAIL_EMAIL => $this->lng->txt('mail_incoming_smtp'),
65 IL_MAIL_BOTH => $this->lng->txt('mail_incoming_both')
66 );
67 $si = new ilSelectInputGUI($this->lng->txt('mail_incoming'), 'mail_incoming_mail');
68 $si->setOptions($options);
69 $this->ctrl->setParameterByClass('ilobjuserfoldergui', 'ref_id', USER_FOLDER_ID);
70 $si->setInfo(sprintf($this->lng->txt('mail_settings_incoming_type_see_also'), $this->ctrl->getLinkTargetByClass('ilobjuserfoldergui', 'settings')));
71 $this->ctrl->clearParametersByClass('ilobjuserfoldergui');
72 $this->form->addItem($si);
73
74 // noreply address
75 $ti = new ilTextInputGUI($this->lng->txt('mail_external_sender_noreply'), 'mail_external_sender_noreply');
76 $ti->setInfo($this->lng->txt('info_mail_external_sender_noreply'));
77 $ti->setMaxLength(255);
78 $this->form->addItem($ti);
79
80 $system_sender_name = new ilTextInputGUI($this->lng->txt('mail_system_sender_name'), 'mail_system_sender_name');
81 $system_sender_name->setInfo($this->lng->txt('mail_system_sender_name_info'));
82 $system_sender_name->setMaxLength(255);
83 $this->form->addItem($system_sender_name);
84
85 $cb = new ilCheckboxInputGUI($this->lng->txt('mail_use_pear_mail'), 'pear_mail_enable');
86 $cb->setInfo($this->lng->txt('mail_use_pear_mail_info'));
87 $cb->setValue(1);
88 $this->form->addItem($cb);
89
90 // prevent smtp mails
91 $cb = new ilCheckboxInputGUI($this->lng->txt('mail_prevent_smtp_globally'), 'prevent_smtp_globally');
92 $cb->setValue(1);
93 $this->form->addItem($cb);
94
95 $cron_mail = new ilSelectInputGUI($this->lng->txt('cron_mail_notification'), 'mail_notification');
96 $cron_options = array(
97 0 => $this->lng->txt('cron_mail_notification_never'),
98 1 => $this->lng->txt('cron_mail_notification_cron')
99 );
100
101 $cron_mail->setOptions($cron_options);
102 $cron_mail->setInfo($this->lng->txt('cron_mail_notification_desc'));
103 $this->form->addItem($cron_mail);
104
105 // section header
106 $sh = new ilFormSectionHeaderGUI();
107 $sh->setTitle($this->lng->txt('mail').' ('.$this->lng->txt('internal_system').')');
108 $this->form->addItem($sh);
109
110 // max attachment size
111 $ti = new ilNumberInputGUI($this->lng->txt('mail_maxsize_attach'), 'mail_maxsize_attach');
112 $ti->setSuffix($this->lng->txt('kb'));
113 $ti->setInfo($this->lng->txt('mail_max_size_attachments_total'));
114 $ti->setMaxLength(10);
115 $ti->setSize(10);
116 $this->form->addItem($ti);
117
118 // Course/Group member notification
119 $mn = new ilFormSectionHeaderGUI();
120 $mn->setTitle($this->lng->txt('mail_member_notification'));
121 $this->form->addItem($mn);
122
123 include_once "Services/Administration/classes/class.ilAdministrationSettingsFormHandler.php";
126 $this->form,
127 $this
128 );
129
130 $this->form->addCommandButton('save', $this->lng->txt('save'));
131 }
const IL_MAIL_BOTH
const IL_MAIL_LOCAL
const IL_MAIL_EMAIL
const USER_FOLDER_ID
Class ilObjUserFolder.
static addFieldsToForm($a_form_id, ilPropertyFormGUI $a_form, ilObjectGUI $a_parent_gui)
This class represents a checkbox property in a property form.
This class represents a section header in a property form.
This class represents a number property in a property form.
This class represents a property form user interface.
This class represents a selection list property in a property form.
This class represents a text property in a property form.
if(!is_array($argv)) $options

References $options, $si, ilAdministrationSettingsFormHandler\addFieldsToForm(), ilAdministrationSettingsFormHandler\FORM_MAIL, IL_MAIL_BOTH, IL_MAIL_EMAIL, IL_MAIL_LOCAL, and USER_FOLDER_ID.

Referenced by saveObject(), and viewObject().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ performImportObject()

ilObjMailGUI::performImportObject ( )

Definition at line 206 of file class.ilObjMailGUI.php.

207 {
208 global $rbacsystem,$lng;
209
210 if (!$rbacsystem->checkAccess('write',$this->object->getRefId()))
211 {
212 $this->ilias->raiseError($this->lng->txt("msg_no_perm_write"),$this->ilias->error_obj->WARNING);
213 }
214 $this->__initFileObject();
215 $this->file_obj->findXMLFile();
216 $this->__initParserObject($this->file_obj->getXMLFile(),"import");
217 $this->parser_obj->startParsing();
218 $number = $this->parser_obj->getCountImported();
219 ilUtil::sendInfo($lng->txt("import_finished")." ".$number,true);
220
221 $this->ctrl->redirect($this, "import");
222 }
__initParserObject($a_xml, $a_mode)
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.

References ilObjectGUI\$lng, __initFileObject(), __initParserObject(), and ilUtil\sendInfo().

+ Here is the call graph for this function:

◆ saveObject()

ilObjMailGUI::saveObject ( )

save object

@access public

Reimplemented from ilObjectGUI.

Definition at line 148 of file class.ilObjMailGUI.php.

149 {
150 global $ilAccess,$ilSetting;
151
152 if(!$ilAccess->checkAccess('write,read', '', $this->object->getRefId()))
153 {
154 $this->ilias->raiseError($this->lng->txt('msg_no_perm_write'), $this->ilias->error_obj->WARNING);
155 }
156
157 $this->initForm();
158 if($this->form->checkInput())
159 {
160 $this->ilias->setSetting('mail_subject_prefix',$this->form->getInput('mail_subject_prefix'));
161 $this->ilias->setSetting('mail_incoming_mail', (int)$this->form->getInput('mail_incoming_mail'));
162 $this->ilias->setSetting('mail_maxsize_attach', $this->form->getInput('mail_maxsize_attach'));
163 $this->ilias->setSetting('pear_mail_enable', (int)$this->form->getInput('pear_mail_enable'));
164 $this->ilias->setSetting('mail_external_sender_noreply', $this->form->getInput('mail_external_sender_noreply'));
165 $this->ilias->setSetting('prevent_smtp_globally', (int)$this->form->getInput('prevent_smtp_globally'));
166 $this->ilias->setSetting('mail_notification', (int)$this->form->getInput('mail_notification'));
167 $ilSetting->set('mail_system_sender_name', $this->form->getInput('mail_system_sender_name'));
168
169 ilUtil::sendSuccess($this->lng->txt('saved_successfully'));
170 }
171 $this->form->setValuesByPost();
172
173 $this->tpl->setContent($this->form->getHTML());
174 }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
global $ilSetting
Definition: privfeed.php:40

References $ilSetting, initForm(), and ilUtil\sendSuccess().

+ Here is the call graph for this function:

◆ setDefaultValues()

ilObjMailGUI::setDefaultValues ( )
private

Definition at line 133 of file class.ilObjMailGUI.php.

134 {
135 $settings = $this->ilias->getAllSettings();
136 $this->form->setValuesByArray(array(
137 'mail_subject_prefix' => $settings['mail_subject_prefix'] ? $settings['mail_subject_prefix'] : '[ILIAS]',
138 'mail_incoming_mail' => (int)$settings['mail_incoming_mail'],
139 'pear_mail_enable' => $settings['pear_mail_enable'] ? true : false,
140 'mail_external_sender_noreply' => $settings['mail_external_sender_noreply'],
141 'prevent_smtp_globally' => ($settings['prevent_smtp_globally'] == '1') ? true : false,
142 'mail_maxsize_attach' => $settings['mail_maxsize_attach'],
143 'mail_notification' => $settings['mail_notification'],
144 'mail_system_sender_name' => $settings['mail_system_sender_name']
145 ));
146 }

Referenced by viewObject().

+ Here is the caller graph for this function:

◆ uploadObject()

ilObjMailGUI::uploadObject ( )

Definition at line 226 of file class.ilObjMailGUI.php.

227 {
228 global $rbacsystem,$lng;
229
230 if (!$rbacsystem->checkAccess('write',$this->object->getRefId()))
231 {
232 $this->ilias->raiseError($this->lng->txt("msg_no_perm_write"),$this->ilias->error_obj->WARNING);
233 }
234
235 $this->__initFileObject();
236 if(!$this->file_obj->storeUploadedFile($_FILES["importFile"])) // STEP 1 save file in ...import/mail
237 {
238 $this->message = $lng->txt("import_file_not_valid");
239 $this->file_obj->unlinkLast();
240 }
241 else if(!$this->file_obj->unzip())
242 {
243 $this->message = $lng->txt("cannot_unzip_file"); // STEP 2 unzip uplaoded file
244 $this->file_obj->unlinkLast();
245 }
246 else if(!$this->file_obj->findXMLFile()) // STEP 3 getXMLFile
247 {
248 $this->message = $lng->txt("cannot_find_xml");
249 $this->file_obj->unlinkLast();
250 }
251 else if(!$this->__initParserObject($this->file_obj->getXMLFile(),"check"))
252 {
253 $this->message = $lng->txt("error_parser"); // STEP 4 init sax parser
254 }
255 else if(!$this->parser_obj->startParsing())
256 {
257 $this->message = $lng->txt("users_not_imported").":<br/>"; // STEP 5 start parsing
258 $this->message .= $this->parser_obj->getNotAssignableUsers();
259 }
260 // FINALLY CHECK ERROR
261 if(!$this->message)
262 {
263 $this->message = $lng->txt("uploaded_and_checked");
264 }
265 ilUtil::sendInfo($this->message,true);
266
267 $this->ctrl->redirect($this, "import");
268 }

References ilObjectGUI\$lng, __initFileObject(), __initParserObject(), and ilUtil\sendInfo().

+ Here is the call graph for this function:

◆ viewObject()

ilObjMailGUI::viewObject ( )

list childs of current object

@access public

Reimplemented from ilObjectGUI.

Definition at line 31 of file class.ilObjMailGUI.php.

32 {
33 global $ilAccess;
34
35 if(!$ilAccess->checkAccess('write,read', '', $this->object->getRefId()))
36 {
37 $this->ilias->raiseError($this->lng->txt('msg_no_perm_write'), $this->ilias->error_obj->WARNING);
38 }
39
40 $this->initForm();
41 $this->setDefaultValues();
42 $this->tpl->setContent($this->form->getHTML());
43 }

References initForm(), and setDefaultValues().

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: