ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilPluginConfigGUI Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Collaboration diagram for ilPluginConfigGUI:

Public Member Functions

 setPluginObject (ilPlugin $a_val)
 
 getPluginObject ()
 
 executeCommand ()
 Execute command. More...
 
 performCommand (string $cmd)
 

Protected Attributes

ilPlugin $plugin_object = null
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Parent class for all plugin config gui classes

You can provide a configuration screen in the ILIAS administration if you implement the class class.il<plugin_name>ConfigGUI.php which should extend ilPluginConfigGUI.

The access the configuration class open the ILIAS Administration > Plugins > Actions (of your Plugin) > Configure

IMPORTANT: Note, that for the configure action to be displayed in your plugins actions dropdown, you need to reload the plugins control structure. You can force your plugin to do so, by updating the plugins version in plugin.php and select Update in the plugins actions in the table in the plugin administration.

Author
Alex Killing <alex.killing>
Version
$Id$

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

Member Function Documentation

◆ executeCommand()

ilPluginConfigGUI::executeCommand ( )

Execute command.

Parameters

Definition at line 55 of file class.ilPluginConfigGUI.php.

References $DIC, $lng, ILIAS\UI\examples\Tree\Expandable\$request_wrapper, $tpl, and performCommand().

55  : void
56  {
57  global $DIC;
58  $ilCtrl = $DIC->ctrl();
59  $ilTabs = $DIC->tabs();
60  $lng = $DIC->language();
61  $tpl = $DIC['tpl'];
62  $request_wrapper = $DIC->http()->wrapper()->query();
63  $string_trafo = $DIC["refinery"]->kindlyTo()->string();
64 
65  $ilCtrl->setParameterByClass("ilobjcomponentsettingsgui", "ctype", $request_wrapper->retrieve("ctype", $string_trafo));
66  $ilCtrl->setParameterByClass("ilobjcomponentsettingsgui", "cname", $request_wrapper->retrieve("cname", $string_trafo));
67  $ilCtrl->setParameterByClass("ilobjcomponentsettingsgui", "slot_id", $request_wrapper->retrieve("slot_id", $string_trafo));
68  $ilCtrl->setParameterByClass("ilobjcomponentsettingsgui", "plugin_id", $request_wrapper->retrieve("plugin_id", $string_trafo));
69  $ilCtrl->setParameterByClass("ilobjcomponentsettingsgui", "pname", $request_wrapper->retrieve("pname", $string_trafo));
70 
71  $tpl->setTitle($lng->txt("cmps_plugin") . ": " . $request_wrapper->retrieve("pname", $string_trafo));
72  $tpl->setDescription("");
73 
74  $ilTabs->clearTargets();
75 
76  if ($request_wrapper->retrieve("plugin_id", $string_trafo)) {
77  $ilTabs->setBackTarget(
78  $lng->txt("cmps_plugin"),
79  $ilCtrl->getLinkTargetByClass("ilobjcomponentsettingsgui", "showPlugin")
80  );
81  } else {
82  $ilTabs->setBackTarget(
83  $lng->txt("cmps_plugins"),
84  $ilCtrl->getLinkTargetByClass("ilobjcomponentsettingsgui", "listPlugins")
85  );
86  }
87 
88  $this->performCommand($ilCtrl->getCmd("configure"));
89  }
$lng
performCommand(string $cmd)
global $DIC
Definition: feed.php:28
if($DIC->http() ->request() ->getMethod()=="GET" &&isset($DIC->http() ->request() ->getQueryParams()['tex'])) $tpl
Definition: latex.php:41
+ Here is the call graph for this function:

◆ getPluginObject()

ilPluginConfigGUI::getPluginObject ( )
final

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

References $plugin_object.

44  : ?ilPlugin
45  {
46  return $this->plugin_object;
47  }

◆ performCommand()

ilPluginConfigGUI::performCommand ( string  $cmd)
abstract

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ setPluginObject()

ilPluginConfigGUI::setPluginObject ( ilPlugin  $a_val)
final

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

39  : void
40  {
41  $this->plugin_object = $a_val;
42  }

Field Documentation

◆ $plugin_object

ilPlugin ilPluginConfigGUI::$plugin_object = null
protected

Definition at line 37 of file class.ilPluginConfigGUI.php.

Referenced by getPluginObject().


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