43 $a_user_image =
false, $a_profile_link =
false, $a_profile_back_link =
"",
44 $a_force_first_lastname =
false, $a_omit_login =
false, $a_sortable =
true)
48 if (!($return_as_array = is_array($a_user_id)))
49 $a_user_id = array($a_user_id);
57 b.value public_profile,
63 (a.usr_id = b.usr_id AND
67 (a.usr_id = c.usr_id AND
69 WHERE ' . $ilDB->in(
'a.usr_id', $a_user_id,
false,
'integer');
71 $userrow = $ilDB->queryF($sql, array(
'text',
'text'), array(
'public_profile',
'public_title'));
75 while (
$row = $ilDB->fetchObject($userrow))
77 if ($a_force_first_lastname ||
78 $has_public_profile = in_array(
$row->public_profile, array(
"y",
"g")))
81 if(
$row->public_title ==
"y" &&
$row->title)
87 $pres =
$row->lastname;
88 if(strlen(
$row->firstname))
90 $pres .= (
', '.$row->firstname.
' ');
96 if(strlen(
$row->firstname))
98 $pres .=
$row->firstname.
' ';
100 $pres .= (
$row->lastname.
' ');
107 $pres.=
"[".$row->login.
"]";
110 if ($a_profile_link && $has_public_profile)
112 $ilCtrl->setParameterByClass(
"ilpublicuserprofilegui",
"user",
$row->usr_id);
113 if ($a_profile_back_link !=
"")
115 $ilCtrl->setParameterByClass(
"ilpublicuserprofilegui",
"back_url",
116 rawurlencode($a_profile_back_link));
118 $pres =
'<a href="'.$ilCtrl->getLinkTargetByClass(
"ilpublicuserprofilegui",
"getHTML").
'">'.$pres.
'</a>';
124 $pres =
'<img border="0" src="'.$img.
'" alt="'.$lng->txt(
"icon").
125 " ".$lng->txt(
"user_picture").
'" /> '.$pres;
128 $names[
$row->usr_id] = $pres;
131 foreach($a_user_id as $id)
134 $names[$id] =
"unknown";
137 return $return_as_array ? $names : $names[$a_user_id[0]];
160 if($ilSetting->get(
'disable_my_offers') == 0 &&
161 $ilSetting->get(
'disable_my_memberships') == 0)
183 if(!$ilSetting->get(
"disable_personal_workspace"))
208 include_once(
'./Services/Calendar/classes/class.ilCalendarSettings.php');
210 if($settings->isEnabled())
234 foreach($all as $idx =>
$lang)
236 $all[$idx] = $lng->txt(
$lang);
253 if($a_value == self::START_REPOSITORY_OBJ)
255 $a_ref_id = (int)$a_ref_id;
257 !$tree->isDeleted($a_ref_id))
259 $ilSetting->set(
"usr_starting_point", $a_value);
260 $ilSetting->set(
"usr_starting_point_ref_id", $a_ref_id);
264 $valid = array_keys(self::getPossibleStartingPoints());
265 if(in_array($a_value,
$valid))
267 $ilSetting->set(
"usr_starting_point", $a_value);
282 $valid = array_keys(self::getPossibleStartingPoints());
283 $current = $ilSetting->get(
"usr_starting_point");
284 if($current == self::START_REPOSITORY_OBJ)
288 else if(!$current || !in_array($current,
$valid))
293 if($ilSetting->get(
'disable_my_offers') == 0 &&
294 $ilSetting->get(
'disable_my_memberships') == 0 &&
295 $ilSetting->get(
'personal_items_default_view') == 1)
302 if($ilUser->getId() == ANONYMOUS_USER_ID)
319 if(self::hasPersonalStartingPoint())
322 if($current == self::START_REPOSITORY_OBJ)
330 if($current == self::START_REPOSITORY_OBJ)
337 case self::START_REPOSITORY:
338 case self::START_REPOSITORY_OBJ:
343 include_once(
'./Services/Link/classes/class.ilLink.php');
352 self::START_PD_OVERVIEW =>
'ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToSelectedItems',
353 self::START_PD_SUBSCRIPTION =>
'ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToMemberships',
357 self::START_PD_WORKSPACE =>
'ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToWorkspace',
361 self::START_PD_CALENDAR =>
'ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToCalendar',
367 return $map[$current];
380 return $ilSetting->get(
"usr_starting_point_ref_id");
392 $ilSetting->set(
"usr_starting_point_personal", (
bool)$a_value);
404 return $ilSetting->get(
"usr_starting_point_personal");
417 $valid = array_keys(self::getPossibleStartingPoints());
418 $current = $ilUser->getPref(
"usr_starting_point");
419 if($current == self::START_REPOSITORY_OBJ)
423 else if(!$current || !in_array($current,
$valid))
441 if($a_value == self::START_REPOSITORY_OBJ)
443 $a_ref_id = (int)$a_ref_id;
445 !$tree->isDeleted($a_ref_id))
447 $ilUser->setPref(
"usr_starting_point", $a_value);
448 $ilUser->setPref(
"usr_starting_point_ref_id", $a_ref_id);
452 $valid = array_keys(self::getPossibleStartingPoints());
453 if(in_array($a_value,
$valid))
455 $ilUser->setPref(
"usr_starting_point", $a_value);
470 $ref_id = $ilUser->getPref(
"usr_starting_point_ref_id");