ILIAS  trunk Revision v11.0_alpha-2662-g519ff7d528f
ilObjFileServicesGUI Class Reference

Class ilObjFileServicesGUI. More...

+ Inheritance diagram for ilObjFileServicesGUI:
+ Collaboration diagram for ilObjFileServicesGUI:

Public Member Functions

 __construct (int $id=0, int $id_type=self::REPOSITORY_NODE_ID, int $parent_node_id=0)
 Constructor public. More...
 
 getType ()
 
 executeCommand ()
 Execute command public. More...
 
 getAdminTabs ()
 Get tabs. More...
 
 setTitleAndDescription ()
 
- Public Member Functions inherited from ilObject2GUI
 __construct (int $id=0, int $id_type=self::REPOSITORY_NODE_ID, int $parent_node_id=0)
 
 executeCommand ()
 execute command More...
 
 getIdType ()
 
 delete ()
 Display delete confirmation form (repository/workspace switch) More...
 
 confirmedDelete ()
 Delete objects (repository/workspace switch) More...
 
 getHTML ()
 
 withReferences ()
 Final/Private declaration of unchanged parent methods. More...
 
 setCreationMode (bool $mode=true)
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 isVisible (int $ref_id, string $type)
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 view ()
 view object content (repository/workspace switch) More...
 
 getType ()
 Functions that must be overwritten. More...
 
 create ()
 CRUD. More...
 
 save ()
 
 edit ()
 
 update ()
 
 cancel ()
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
- Public Member Functions inherited from ilObjectGUI
 getRefId ()
 
 setAdminMode (string $mode)
 
 getAdminMode ()
 
 getObject ()
 
 executeCommand ()
 
 withReferences ()
 determines whether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode (bool $mode=true)
 If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI. More...
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 getAdminTabs ()
 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...
 
 cancelObject ()
 cancel action and go back to previous page More...
 
 createObject ()
 create new object form More...
 
 editAvailabilityPeriodObject ()
 
 saveAvailabilityPeriodObject ()
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 
 getDidacticTemplateVar (string $type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 
 addExternalEditFormCustom (ilPropertyFormGUI $form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction (string $cmd, string $default_form_action="")
 Get form action for command (command is method name without "Object", e.g. More...
 
 isVisible (int $ref_id, string $type)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 deleteObject (bool $error=false)
 Display deletion confirmation screen. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 addToDeskObject ()
 
 removeFromDeskObject ()
 
- Public Member Functions inherited from ILIAS\Object\ImplementsCreationCallback
 callCreationCallback (\ilObject $object, \ilObjectDefinition $obj_definition, int $requested_crtcb)
 

Data Fields

const CMD_EDIT_SETTINGS = 'editSettings'
 
ilLanguage $lng
 
ilErrorHandling $error_handling
 
ilGlobalTemplateInterface $tpl
 
- Data Fields inherited from ilObject2GUI
const OBJECT_ID = 0
 
const REPOSITORY_NODE_ID = 1
 
const WORKSPACE_NODE_ID = 2
 
const REPOSITORY_OBJECT_ID = 3
 
const WORKSPACE_OBJECT_ID = 4
 
const PORTFOLIO_OBJECT_ID = 5
 
- Data Fields inherited from ilObjectGUI
const ADMIN_MODE_NONE = ""
 
const ADMIN_MODE_SETTINGS = "settings"
 
const ADMIN_MODE_REPOSITORY = "repository"
 
const UPLOAD_TYPE_LOCAL = 1
 
const UPLOAD_TYPE_UPLOAD_DIRECTORY = 2
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 
const SUPPORTED_IMPORT_MIME_TYPES = [MimeType::APPLICATION__ZIP, MimeType::APPLICATION__X_ZIP_COMPRESSED]
 

Protected Member Functions

 checkPermissionOrFail (string $str)
 
 hasUserPermissionTo (string $str)
 
 editSettings ()
 
 saveSettings ()
 
- Protected Member Functions inherited from ilObject2GUI
 afterConstructor ()
 Do anything that should be done after constructor in here. More...
 
 assignObject ()
 create object instance as internal property (repository/workspace switch) More...
 
 getAccessHandler ()
 
 setLocator ()
 set Locator More...
 
 deleteConfirmedObjects ()
 Delete objects (workspace specific) This should probably be moved elsewhere as done with RepUtil. More...
 
 setTitleAndDescription ()
 
 omitLocator (bool $omit=true)
 
 getTargetFrame (string $cmd, string $target_frame="")
 
 setTargetFrame (string $cmd, string $target_frame)
 
 getCenterColumnHTML ()
 
 getRightColumnHTML ()
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 showPossibleSubObjects ()
 
 redirectToRefId (int $ref_id, string $cmd="")
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 
 setTabs ()
 create tabs (repository/workspace switch) More...
 
 getReturnLocation (string $cmd, string $location="")
 Deprecated functions. More...
 
 setReturnLocation (string $cmd, string $location)
 
 showActions ()
 
 getTabs ()
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $node_id=null)
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 redrawHeaderAction ()
 Updating icons after ajax call. More...
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 
 assignObject ()
 
 setTitleAndDescription ()
 
 createActionDispatcherGUI ()
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction (?ilObjectListGUI $list_gui=null)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 setTabs ()
 set admin tabs More...
 
 setAdminTabs ()
 set admin tabs More...
 
 setLocator ()
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator (bool $omit=true)
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 getCreationFormsHTML (StandardForm|ilPropertyFormGUI|array $form)
 
 getTitleForCreationFormPage ()
 
 getCreationFormTitle ()
 
 initCreateForm (string $new_type)
 
 didacticTemplatesToForm ()
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 
 retrieveAdditionalDidacticTemplateOptions ()
 
 addAdoptContentLinkToToolbar ()
 
 addImportButtonToToolbar ()
 
 addAvailabilityPeriodButtonToToolbar (ilToolbarGUI $toolbar)
 
 parseDidacticTemplateVar (string $var, string $type)
 
 afterSave (ilObject $new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 routeImportCmdObject ()
 
 importFile (string $file_to_import, string $path_to_uploaded_file_in_temp_dir)
 
 deleteUploadedImportFile (string $path_to_uploaded_file_in_temp_dir)
 
 afterImport (ilObject $new_object)
 Post (successful) object import hook. More...
 
 setFormAction (string $cmd, string $form_action)
 
 getReturnLocation (string $cmd, string $default_location="")
 Get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation (string $cmd, string $location)
 set specific return location for command More...
 
 getTargetFrame (string $cmd, string $default_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame (string $cmd, string $target_frame)
 Set specific target frame for command. More...
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) More...
 
 getTabs ()
 overwrite in derived GUI class of your object type More...
 
 redirectToRefId (int $ref_id, string $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 ["ref_id"] value of the request More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 getCreatableObjectTypes ()
 
 buildAddNewItemElements (array $subtypes, string $create_target_class=ilRepositoryGUI::class, ?int $redirect_target_ref_id=null,)
 
 buildGroup (string $create_target_class, array $obj_types_in_group, string $title, array $subtypes)
 

Protected Attributes

const TAB_PERMISSIONS = 'perm_settings'
 
const TAB_SETTINGS = 'settings'
 
const TAB_OVERVIEW = 'resource_overview'
 
const TAB_UPLOAD_LIMITS = 'upload_limits'
 
ilTabsGUI $tabs
 
ilCtrl $ctrl
 
ilSetting $settings
 
Factory $refinery
 
ilFileServicesSettings $file_service_settings
 
- Protected Attributes inherited from ilObject2GUI
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilCtrl $ctrl
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ilFavouritesManager $favourites
 
ilErrorHandling $error
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilToolbarGUI $toolbar
 
Factory $refinery
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
int $request_ref_id
 
int $id_type
 
int $parent_id
 
string $type
 
string $html
 
int $object_id
 
int $node_id = null
 
array $creation_forms = []
 
 $access_handler
 
- Protected Attributes inherited from ilObjectGUI
ILIAS Notes Service $notes_service
 
GlobalHttpState $http
 
ServerRequestInterface $request
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilSetting $settings
 
ilToolbarGUI $toolbar
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
ilObjectService $object_service
 
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilTree $tree
 
ilCtrl $ctrl
 
ilErrorHandling $error
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ILIAS $ilias
 
ArrayBasedRequestWrapper $post_wrapper
 
RequestWrapper $request_wrapper
 
Refinery $refinery
 
ilFavouritesManager $favourites
 
CustomIconFactory $custom_icon_factory
 
UIFactory $ui_factory
 
UIRenderer $ui_renderer
 
Filesystem $temp_file_system
 
ilObject $object = null
 
bool $creation_mode = false
 
 $data
 
int $id
 
bool $call_by_reference = false
 
bool $prepare_output
 
int $ref_id
 
int $obj_id
 
int $maxcount
 
array $form_action = []
 
array $return_location = []
 
array $target_frame = []
 
string $tmp_import_dir
 
string $sub_objects = ""
 
bool $omit_locator = false
 
string $type = ""
 
string $admin_mode = self::ADMIN_MODE_NONE
 
int $requested_ref_id = 0
 
int $requested_crtptrefid = 0
 
int $requested_crtcb = 0
 
string $requested_new_type = ""
 
string $link_params
 
string $html = ""
 

Private Member Functions

 initSettingsForm ()
 

Additional Inherited Members

- Static Public Member Functions inherited from ilObject2GUI
static handleAfterSaveCallback (ilObject $obj, ?int $callback_ref_id)
 After creation callback. More...
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot (bool $raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode (int $ref_id, string $cmd="")
 
static _gotoSharedWorkspaceNode (int $wsp_id)
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjFileServicesGUI::__construct ( int  $id = 0,
int  $id_type = self::REPOSITORY_NODE_ID,
int  $parent_node_id = 0 
)

Constructor public.

Definition at line 51 of file class.ilObjFileServicesGUI.php.

References $DIC, ilObjectGUI\$id, ilObject2GUI\$id_type, ILIAS\GlobalScreen\Provider\__construct(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ILIAS\Repository\refinery(), ILIAS\Repository\settings(), ILIAS\Repository\tabs(), and ilObjFileServices\TYPE_FILE_SERVICES.

52  {
53  global $DIC;
54 
56  parent::__construct($id, $id_type, $parent_node_id);
57 
58  $this->tabs = $DIC['ilTabs'];
59  $this->lng = $DIC->language();
60  $this->lng->loadLanguageModule('adn');
61  $this->lng->loadLanguageModule('irss');
62  $this->ctrl = $DIC['ilCtrl'];
63  $this->tpl = $DIC['tpl'];
64  $this->tree = $DIC['tree'];
65  $this->settings = $DIC['ilSetting'];
66  $this->error_handling = $DIC["ilErr"];
67  $this->ref_id = $this->request_wrapper->retrieve('ref_id', $DIC->refinery()->kindlyTo()->int());
68  $this->refinery = $DIC->refinery();
69  $this->file_service_settings = $DIC->fileServiceSettings();
70  }
global $DIC
Definition: shib_login.php:26
__construct(Container $dic, ilPlugin $plugin)
+ Here is the call graph for this function:

Member Function Documentation

◆ checkPermissionOrFail()

ilObjFileServicesGUI::checkPermissionOrFail ( string  $str)
protected

Definition at line 77 of file class.ilObjFileServicesGUI.php.

References hasUserPermissionTo(), and ILIAS\Repository\lng().

Referenced by editSettings(), executeCommand(), and saveSettings().

77  : void
78  {
79  if (!$this->hasUserPermissionTo($str)) {
80  $this->error_handling->raiseError(
81  $this->lng->txt('no_permission'),
82  $this->error->MESSAGE
83  );
84  }
85  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ editSettings()

ilObjFileServicesGUI::editSettings ( )
protected

Definition at line 258 of file class.ilObjFileServicesGUI.php.

References checkPermissionOrFail(), and initSettingsForm().

258  : void
259  {
260  $this->tabs_gui->setTabActive(self::TAB_SETTINGS);
261 
262  $this->checkPermissionOrFail("visible,read");
263 
264  // get form
265  $form = $this->initSettingsForm();
266 
267  // set current values
268  $val = [];
269  $val["suffix_repl_additional"] = implode(", ", $this->file_service_settings->getWhiteListNegative());
270  $val["suffix_custom_white_list"] = implode(", ", $this->file_service_settings->getWhiteListPositive());
271  $val["suffix_custom_expl_black"] = implode(", ", $this->file_service_settings->getProhibited());
272  $form->setValuesByArray($val);
273 
274  // set content
275  $this->tpl->setContent($form->getHTML());
276  }
+ Here is the call graph for this function:

◆ executeCommand()

ilObjFileServicesGUI::executeCommand ( )

Execute command public.

Definition at line 97 of file class.ilObjFileServicesGUI.php.

References checkPermissionOrFail(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ilObject2GUI\prepareOutput().

97  : void
98  {
99  $this->lng->loadLanguageModule("fils");
100 
101  $next_class = $this->ctrl->getNextClass($this);
102  $cmd = $this->ctrl->getCmd();
103 
104  $this->prepareOutput();
105  $this->checkPermissionOrFail('read');
106 
107  switch ($next_class) {
108  case strtolower(ilPermissionGUI::class):
109  $this->tabs_gui->activateTab(self::TAB_PERMISSIONS);
110  $perm_gui = new ilPermissionGUI($this);
111  $this->ctrl->forwardCommand($perm_gui);
112  break;
113  case strtolower(ilResourceOverviewGUI::class):
114  $this->tabs_gui->activateTab(self::TAB_OVERVIEW);
115  $overview = new ilResourceOverviewGUI();
116  $this->ctrl->forwardCommand($overview);
117  break;
118  case strtolower(ilUploadLimitsOverviewGUI::class):
119  $this->tabs_gui->activateTab(self::TAB_UPLOAD_LIMITS);
120  $limits_gui = new ilUploadLimitsOverviewGUI();
121  $this->ctrl->forwardCommand($limits_gui);
122  break;
123  default:
124  if (!$cmd || $cmd === 'view') {
125  $cmd = self::CMD_EDIT_SETTINGS;
126  }
127  $this->$cmd();
128  break;
129  }
130  }
prepareOutput(bool $show_sub_objects=true)
+ Here is the call graph for this function:

◆ getAdminTabs()

ilObjFileServicesGUI::getAdminTabs ( )

Get tabs.

Definition at line 136 of file class.ilObjFileServicesGUI.php.

References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

136  : void
137  {
138  // General Settings for File-Services
139  if ($this->rbac_system->checkAccess(
140  "visible,read",
141  $this->object->getRefId()
142  )
143  ) {
144  $this->tabs_gui->addTab(
145  self::TAB_SETTINGS,
146  $this->lng->txt(self::TAB_SETTINGS),
147  $this->ctrl->getLinkTarget($this, self::CMD_EDIT_SETTINGS)
148  );
149  }
150  // Resource-Overview
151  if ($this->rbac_system->checkAccess(
152  "visible,read",
153  $this->object->getRefId()
154  )
155  ) {
156  $this->tabs_gui->addTab(
157  self::TAB_OVERVIEW,
158  $this->lng->txt(self::TAB_OVERVIEW),
159  $this->ctrl->getLinkTargetByClass(ilResourceOverviewGUI::class),
160  );
161  }
162  // Upload-Limit
163  if ($this->rbac_system->checkAccess(
164  "visible,read",
165  $this->object->getRefId()
166  )
167  ) {
168  $this->tabs_gui->addTab(
169  self::TAB_UPLOAD_LIMITS,
170  $this->lng->txt(self::TAB_UPLOAD_LIMITS),
171  $this->ctrl->getLinkTargetByClass(ilUploadLimitsOverviewGUI::class),
172  );
173  }
174  // Permissions-tab
175  if ($this->rbac_system->checkAccess(
176  'edit_permission',
177  $this->object->getRefId()
178  )
179  ) {
180  $this->tabs_gui->addTab(
181  self::TAB_PERMISSIONS,
182  $this->lng->txt(self::TAB_PERMISSIONS),
183  $this->ctrl->getLinkTargetByClass(ilPermissionGUI::class, "perm")
184  );
185  }
186  }
+ Here is the call graph for this function:

◆ getType()

ilObjFileServicesGUI::getType ( )

Definition at line 72 of file class.ilObjFileServicesGUI.php.

References ilObjFileServices\TYPE_FILE_SERVICES.

72  : string
73  {
75  }

◆ hasUserPermissionTo()

ilObjFileServicesGUI::hasUserPermissionTo ( string  $str)
protected

Definition at line 87 of file class.ilObjFileServicesGUI.php.

References ILIAS\Repository\access().

Referenced by checkPermissionOrFail(), and initSettingsForm().

87  : bool
88  {
89  return $this->access->checkAccess($str, '', $this->ref_id);
90  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initSettingsForm()

ilObjFileServicesGUI::initSettingsForm ( )
private

Definition at line 195 of file class.ilObjFileServicesGUI.php.

References ILIAS\Repository\ctrl(), hasUserPermissionTo(), ILIAS\Repository\lng(), and ilFormPropertyGUI\setInfo().

Referenced by editSettings(), and saveSettings().

196  {
197  $permission_to_write = $this->hasUserPermissionTo('write');
198 
199  $form = new ilPropertyFormGUI();
200  $form->setFormAction($this->ctrl->getFormAction($this));
201  $form->setTitle($this->lng->txt(self::TAB_SETTINGS));
202 
203  // default positive list
204  $ne = new ilNonEditableValueGUI($this->lng->txt("file_suffix_default_positive"), "");
205  $ne->setValue(implode(", ", $this->file_service_settings->getDefaultWhitelist()));
206  $ne->setInfo($this->lng->txt("file_suffix_default_positive_info"));
207  $form->addItem($ne);
208 
209  // file suffix custom negative list
210  $ta = new ilTextAreaInputGUI(
211  $this->lng->txt(
212  "file_suffix_custom_negative"
213  ),
214  "suffix_repl_additional"
215  );
216  $ta->setInfo($this->lng->txt("file_suffix_custom_negative_info"));
217  $ta->setRows(5);
218  $ta->setDisabled(!$permission_to_write);
219  $form->addItem($ta);
220 
221  // file suffix custom positive list
222  $ta = new ilTextAreaInputGUI(
223  $this->lng->txt(
224  "file_suffix_custom_positive"
225  ),
226  "suffix_custom_white_list"
227  );
228  $ta->setInfo($this->lng->txt("file_suffix_custom_positive_info"));
229  $ta->setRows(5);
230  $ta->setDisabled(!$permission_to_write);
231  $form->addItem($ta);
232 
233  // resulting overall positive list
234  $ne = new ilNonEditableValueGUI($this->lng->txt("file_suffix_overall_positive"), "");
235  $ne->setValue(implode(", ", $this->file_service_settings->getWhiteListedSuffixes()));
236  $ne->setInfo($this->lng->txt("file_suffix_overall_positive_info"));
237  $form->addItem($ne);
238 
239  // explicit negative list
240  $ta = new ilTextAreaInputGUI(
241  $this->lng->txt("file_suffix_custom_expl_negative"),
242  "suffix_custom_expl_black"
243  );
244  $ta->setInfo($this->lng->txt("file_suffix_custom_expl_negative_info"));
245  $ta->setRows(5);
246  $ta->setDisabled(!$permission_to_write);
247  $form->addItem($ta);
248 
249  // command buttons
250  if ($permission_to_write) {
251  $form->addCommandButton('saveSettings', $this->lng->txt('save'));
252  $form->addCommandButton('view', $this->lng->txt('cancel'));
253  }
254 
255  return $form;
256  }
This class represents a text area property in a property form.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ saveSettings()

ilObjFileServicesGUI::saveSettings ( )
protected

Definition at line 278 of file class.ilObjFileServicesGUI.php.

References ilObjectGUI\$id, checkPermissionOrFail(), ILIAS\Repository\ctrl(), initSettingsForm(), ILIAS\Repository\lng(), null, ILIAS\Repository\refinery(), and ILIAS\Repository\settings().

278  : void
279  {
280  $this->checkPermissionOrFail("write");
281 
282  // get form
283  $form = $this->initSettingsForm();
284  if ($form->checkInput()) {
285  $trafo = (fn(string $id): ?string => $this->post_wrapper->has($id)
286  ? $this->post_wrapper->retrieve($id, $this->refinery->to()->string())
287  : null);
288 
289 
290  $this->settings->set("suffix_repl_additional", $trafo("suffix_repl_additional"));
291  $this->settings->set("suffix_custom_white_list", $trafo("suffix_custom_white_list"));
292  $this->settings->set("suffix_custom_expl_black", $trafo("suffix_custom_expl_black"));
293 
294  $this->tpl->setOnScreenMessage('success', $this->lng->txt('settings_saved'), true);
295  $this->ctrl->redirect($this, self::CMD_EDIT_SETTINGS);
296  } else {
297  $form->setValuesByPost();
298  $this->tpl->setContent($form->getHTML());
299  }
300  }
has(string $class_name)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
to(\GdImage $image, ?int $quality=null)
Currently this is the only way to make a FileStream from a GD image resource.
+ Here is the call graph for this function:

◆ setTitleAndDescription()

ilObjFileServicesGUI::setTitleAndDescription ( )

Definition at line 189 of file class.ilObjFileServicesGUI.php.

References ILIAS\Repository\object().

189  : void
190  {
191  parent::setTitleAndDescription();
192  $this->tpl->setDescription($this->object->getDescription());
193  }
+ Here is the call graph for this function:

Field Documentation

◆ $ctrl

ilCtrl ilObjFileServicesGUI::$ctrl
protected

Definition at line 41 of file class.ilObjFileServicesGUI.php.

◆ $error_handling

ilErrorHandling ilObjFileServicesGUI::$error_handling

Definition at line 40 of file class.ilObjFileServicesGUI.php.

◆ $file_service_settings

ilFileServicesSettings ilObjFileServicesGUI::$file_service_settings
protected

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

◆ $lng

ilLanguage ilObjFileServicesGUI::$lng

Definition at line 39 of file class.ilObjFileServicesGUI.php.

◆ $refinery

Factory ilObjFileServicesGUI::$refinery
protected

Definition at line 44 of file class.ilObjFileServicesGUI.php.

◆ $settings

ilSetting ilObjFileServicesGUI::$settings
protected

Definition at line 42 of file class.ilObjFileServicesGUI.php.

◆ $tabs

ilTabsGUI ilObjFileServicesGUI::$tabs
protected

Definition at line 38 of file class.ilObjFileServicesGUI.php.

◆ $tpl

ilGlobalTemplateInterface ilObjFileServicesGUI::$tpl

Definition at line 43 of file class.ilObjFileServicesGUI.php.

◆ CMD_EDIT_SETTINGS

const ilObjFileServicesGUI::CMD_EDIT_SETTINGS = 'editSettings'

Definition at line 32 of file class.ilObjFileServicesGUI.php.

◆ TAB_OVERVIEW

const ilObjFileServicesGUI::TAB_OVERVIEW = 'resource_overview'
protected

Definition at line 35 of file class.ilObjFileServicesGUI.php.

◆ TAB_PERMISSIONS

const ilObjFileServicesGUI::TAB_PERMISSIONS = 'perm_settings'
protected

Definition at line 33 of file class.ilObjFileServicesGUI.php.

◆ TAB_SETTINGS

const ilObjFileServicesGUI::TAB_SETTINGS = 'settings'
protected

Definition at line 34 of file class.ilObjFileServicesGUI.php.

◆ TAB_UPLOAD_LIMITS

const ilObjFileServicesGUI::TAB_UPLOAD_LIMITS = 'upload_limits'
protected

Definition at line 36 of file class.ilObjFileServicesGUI.php.


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