ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilUserUserActionProvider Class Reference

Adds link to profile. More...

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

Public Member Functions

 getComponentId ()
 
 getActionTypes ()
 
 collectActionsForTargetUser ($a_target_user)
 Collect all actions. More...
 
- Public Member Functions inherited from ilUserActionProvider
 __construct ()
 Constructor. More...
 
 setUserId ($a_val)
 Set user id. More...
 
 getUserId ()
 Get user id. More...
 
 collectActionsForTargetUser ($a_target_user)
 Collect actions for a target user. More...
 
 getComponentId ()
 
 getActionTypes ()
 
 getJsScripts ($a_action_type)
 Get js scripts. More...
 
 getCssFiles ($a_action_type)
 Get css resource files. More...
 

Additional Inherited Members

- Protected Attributes inherited from ilUserActionProvider
 $user_id
 
 $lng
 
 $db
 

Detailed Description

Adds link to profile.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

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

Member Function Documentation

◆ collectActionsForTargetUser()

ilUserUserActionProvider::collectActionsForTargetUser (   $a_target_user)

Collect all actions.

Parameters
int$a_target_usertarget user
Returns
ilUserActionCollection collection

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

References $f, ilObjUser\_lookupPref(), and ilUserActionCollection\getInstance().

41  {
43  include_once("./Services/User/Actions/classes/class.ilUserAction.php");
44 
45  if (!in_array(
46  ilObjUser::_lookupPref($a_target_user, "public_profile"),
47  array("y", "g")
48  )) {
49  return $coll;
50  }
51 
52  $f = new ilUserAction();
53  $f->setType("profile");
54  $f->setText($this->lng->txt('profile'));
55  $f->setHref("./goto.php?target=usr_" . $a_target_user);
56  $coll->addAction($f);
57 
58  return $coll;
59  }
static getInstance()
Get instance.
static _lookupPref($a_usr_id, $a_keyword)
Action that can be performed on a user.
+ Here is the call graph for this function:

◆ getActionTypes()

ilUserUserActionProvider::getActionTypes ( )

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

28  {
29  return array(
30  "profile" => $this->lng->txt("profile")
31  );
32  }

◆ getComponentId()

ilUserUserActionProvider::getComponentId ( )

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

20  {
21  return "user";
22  }

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