ILIAS  trunk Revision v11.0_alpha-1749-g1a06bdef097
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilUserUserActionProvider Class Reference

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

+ Inheritance diagram for ilUserUserActionProvider:
+ Collaboration diagram for ilUserUserActionProvider:

Public Member Functions

 getComponentId ()
 
 getActionTypes ()
 
 collectActionsForTargetUser (int $a_target_user)
 
- Public Member Functions inherited from ilUserActionProvider
 __construct ()
 
 setUserId (int $a_val)
 
 getUserId ()
 
 collectActionsForTargetUser (int $a_target_user)
 Collect actions for a target user. More...
 
 getComponentId ()
 
 getActionTypes ()
 
 getJsScripts (string $a_action_type)
 

Additional Inherited Members

- Protected Attributes inherited from ilUserActionProvider
int $user_id
 
Language $lng
 
ilDBInterface $db
 

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 Adds link to profile

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

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

Member Function Documentation

◆ collectActionsForTargetUser()

ilUserUserActionProvider::collectActionsForTargetUser ( int  $a_target_user)

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

References Vendor\Package\$f, ilObjUser\_lookupPref(), and ILIAS\Repository\lng().

41  {
42  $coll = new ilUserActionCollection();
43 
44  if (!in_array(
45  ilObjUser::_lookupPref($a_target_user, "public_profile"),
46  ["y", "g"]
47  )) {
48  return $coll;
49  }
50 
51  $f = new ilUserAction();
52  $f->setType("profile");
53  $f->setText($this->lng->txt('profile'));
54  $f->setHref("./goto.php?target=usr_" . $a_target_user);
55  $coll->addAction($f);
56 
57  return $coll;
58  }
static _lookupPref(int $a_usr_id, string $a_keyword)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the call graph for this function:

◆ getActionTypes()

ilUserUserActionProvider::getActionTypes ( )
Returns
array<string,string>

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

References ILIAS\Repository\lng().

33  : array
34  {
35  return [
36  "profile" => $this->lng->txt("profile")
37  ];
38  }
+ Here is the call graph for this function:

◆ getComponentId()

ilUserUserActionProvider::getComponentId ( )

Definition at line 25 of file class.ilUserUserActionProvider.php.

25  : string
26  {
27  return "user";
28  }

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