ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
ilAwarenessWorkspaceFeatureProvider Class Reference

Adds link to shared resources feature. More...

+ Inheritance diagram for ilAwarenessWorkspaceFeatureProvider:
+ Collaboration diagram for ilAwarenessWorkspaceFeatureProvider:

Public Member Functions

 __construct ()
 Construct. More...
 
 collectFeaturesForTargetUser ($a_target_user)
 Collect all features. More...
 
- Public Member Functions inherited from ilAwarenessFeatureProvider
 __construct ()
 Constructor. More...
 
 setUserId ($a_val)
 Set user id. More...
 
 getUserId ()
 Get user id. More...
 
 collectFeaturesForTargetUser ($a_target_user)
 Collect features for a target user. More...
 

Protected Attributes

 $wsp_activated
 
- Protected Attributes inherited from ilAwarenessFeatureProvider
 $user_id
 
 $lng
 
 $db
 

Detailed Description

Adds link to shared resources feature.

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.ilAwarenessWorkspaceFeatureProvider.php.

Constructor & Destructor Documentation

◆ __construct()

ilAwarenessWorkspaceFeatureProvider::__construct ( )

Construct.

Parameters

Definition at line 24 of file class.ilAwarenessWorkspaceFeatureProvider.php.

References $ilSetting, and ilAwarenessFeatureProvider\$lng.

25  {
26  global $lng, $ilSetting;
27 
28  $this->wsp_activated = (!$ilSetting->get("disable_personal_workspace"));
29  $lng->loadLanguageModule("wsp");
30  parent::__construct();
31  }
global $ilSetting
Definition: privfeed.php:40

Member Function Documentation

◆ collectFeaturesForTargetUser()

ilAwarenessWorkspaceFeatureProvider::collectFeaturesForTargetUser (   $a_target_user)

Collect all features.

Parameters
int$a_target_usertarget user
Returns
ilAwarenessUserCollection collection

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

References $ilCtrl, ilAwarenessFeatureProvider\$lng, ilObjUser\_lookupLogin(), and ilAwarenessFeatureCollection\getInstance().

41  {
42  global $ilCtrl, $lng;
43 
45  include_once("./Services/Awareness/classes/class.ilAwarenessFeature.php");
46 
47  if (!$this->wsp_activated)
48  {
49  return $coll;
50  }
51 
52  $f = new ilAwarenessFeature();
53  $f->setText($lng->txt("wsp_shared_resources"));
54  $ilCtrl->setParameterByClass("ilobjworkspacerootfoldergui", "user", ilObjUser::_lookupLogin($a_target_user));
55  $f->setHref($ilCtrl->getLinkTargetByClass(array("ilpersonaldesktopgui", "ilpersonalworkspacegui", "ilobjworkspacerootfoldergui"),
56  "listSharedResourcesOfOtherUser"));
57 
58  //$f->setData(array("test" => "you", "user" => $a_target_user));
59 
60  $coll->addFeature($f);
61 
62  return $coll;
63  }
static _lookupLogin($a_user_id)
lookup login
global $ilCtrl
Definition: ilias.php:18
Awareness tool feature (presented in user drop downs) (data object)
+ Here is the call graph for this function:

Field Documentation

◆ $wsp_activated

ilAwarenessWorkspaceFeatureProvider::$wsp_activated
protected

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