ilForumAuthorInformationCache
More...
◆ getUserObjectById()
static ilForumAuthorInformationCache::getUserObjectById |
( |
|
$usr_id | ) |
|
|
static |
◆ preloadUserObjects()
static ilForumAuthorInformationCache::preloadUserObjects |
( |
array |
$usr_ids | ) |
|
|
static |
- Parameters
-
Definition at line 34 of file class.ilForumAuthorInformationCache.php.
References $DIC, $ilDB, $in, $query, $res, $row, and $user.
Referenced by ilForumTopic\getNestedSetPostChildren(), ilForumTopic\getPostTree(), ilForumTopicTableGUI\numericOrdering(), and ilForumCronNotification\sendCronForumNotification().
37 $ilDB = $DIC->database();
39 $usr_ids_to_request = array_diff($usr_ids, self::$requested_usr_ids);
40 self::$requested_usr_ids = array_merge(self::$requested_usr_ids, $usr_ids_to_request);
41 self::$requested_usr_ids_key_map = array_flip(self::$requested_usr_ids);
43 if ($usr_ids_to_request) {
44 $in =
$ilDB->in(
'ud.usr_id', $usr_ids_to_request,
false,
'integer');
46 SELECT ud.usr_id, od.create_date, login, firstname, lastname, ud.title, gender, pprof.value public_profile, pgen.value public_gender, pup.value public_upload 48 INNER JOIN object_data od ON od.obj_id = ud.usr_id 49 LEFT JOIN usr_pref pprof ON pprof.usr_id = ud.usr_id AND pprof.keyword = %s 50 LEFT JOIN usr_pref pgen ON pgen.usr_id = ud.usr_id AND pgen.keyword = %s 51 LEFT JOIN usr_pref pup ON pup.usr_id = ud.usr_id AND pup.keyword = %s 57 array(
'text',
'text',
'text'),
58 array(
'public_profile',
'public_gender',
'public_upload')
70 $user->setPref(
'public_profile',
$row[
'public_profile']);
71 $user->setPref(
'public_gender',
$row[
'public_gender']);
72 $user->setPref(
'public_upload',
$row[
'public_upload']);
74 self::$user_instances[
$row[
'usr_id']] =
$user;
foreach($_POST as $key=> $value) $res
if(php_sapi_name() !='cli') $in
◆ $requested_usr_ids
ilForumAuthorInformationCache::$requested_usr_ids = array() |
|
staticprotected |
◆ $requested_usr_ids_key_map
ilForumAuthorInformationCache::$requested_usr_ids_key_map = array() |
|
staticprotected |
◆ $user_instances
ilForumAuthorInformationCache::$user_instances = array() |
|
staticprotected |
The documentation for this class was generated from the following file: