A class that provides a collection of actions on users.
More...
A class that provides a collection of actions on users.
- Author
- Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
- Version
- $Id$
Definition at line 12 of file class.ilUserActionGUI.php.
◆ __construct()
Constructor.
- Parameters
-
Definition at line 41 of file class.ilUserActionGUI.php.
46 $this->tpl = $a_global_tpl;
47 $this->user_action_context = $a_user_action_context;
48 $this->current_user_id = $a_current_user_id;
◆ getInstance()
◆ init()
ilUserActionGUI::init |
( |
| ) |
|
Add requried js for an action context.
Definition at line 67 of file class.ilUserActionGUI.php.
References $tpl, $txt, ilUserActionProviderFactory\getAllProviders(), and ilUserActionAdmin\lookupActive().
Referenced by renderDropDown().
71 include_once(
"./Services/User/Actions/classes/class.ilUserActionAdmin.php");
72 include_once(
"./Services/User/Actions/classes/class.ilUserActionProviderFactory.php");
74 foreach ($prov->getActionTypes() as $act_type =>
$txt) {
76 $this->user_action_context->getComponentId(),
77 $this->user_action_context->getContextId(),
78 $prov->getComponentId(),
81 foreach ($prov->getJsScripts($act_type) as $script) {
82 $tpl->addJavascript($script);
static getAllProviders()
Get all action providers.
static lookupActive($a_context_comp, $a_context_id, $a_action_comp, $a_action_type)
Is activated?
◆ renderDropDown()
ilUserActionGUI::renderDropDown |
( |
|
$a_target_user_id | ) |
|
Render drop down.
- Parameters
-
int | $a_user_id | target user id |
- Returns
- string
Definition at line 95 of file class.ilUserActionGUI.php.
References $action, $list, ilUserActionCollector\getInstance(), and init().
97 if (!$this->init_done) {
100 include_once(
"./Services/User/Gallery/classes/class.ilGalleryUserActionContext.php");
101 include_once(
"./Services/User/Actions/classes/class.ilUserActionCollector.php");
103 $action_collection = $act_collector->getActionsForTargetUser($a_target_user_id);
104 include_once(
"./Services/UIComponent/AdvancedSelectionList/classes/class.ilAdvancedSelectionListGUI.php");
106 $list->setListTitle(
"");
107 foreach ($action_collection->getActions() as
$action) {
108 $list->addItem(
$action->getText(),
"",
$action->getHref(),
"",
"",
"",
"",
false,
"",
"",
"",
"",
true,
$action->getData());
110 return $list->getHTML();
if(isset($_REQUEST['delete'])) $list
static getInstance($a_user_id, ilUserActionContext $a_context)
Get instance (for a user)
User interface class for advanced drop-down selection lists.
init()
Add requried js for an action context.
◆ $current_user_id
ilUserActionGUI::$current_user_id |
|
protected |
◆ $init_done
ilUserActionGUI::$init_done = false |
|
protected |
◆ $tpl
◆ $user_action_context
ilUserActionGUI::$user_action_context |
|
protected |
The documentation for this class was generated from the following file: