mirror of
https://github.com/friendica/friendica
synced 2025-05-05 23:04:09 +02:00
Performance improvements when displaying local posts
This commit is contained in:
parent
bae1f63424
commit
c82a1ed467
16 changed files with 1101 additions and 28 deletions
|
@ -379,6 +379,21 @@ class Post
|
|||
return self::selectView('post-user-view', $selected, $condition, $params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Select rows from the post-origin-view view
|
||||
*
|
||||
* @param array $selected Array of selected fields, empty for all
|
||||
* @param array $condition Array of fields for condition
|
||||
* @param array $params Array of several parameters
|
||||
*
|
||||
* @return boolean|object
|
||||
* @throws \Exception
|
||||
*/
|
||||
public static function selectOrigin(array $selected = [], array $condition = [], array $params = [])
|
||||
{
|
||||
return self::selectView('post-origin-view', $selected, $condition, $params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Select rows from the post-view view
|
||||
*
|
||||
|
@ -424,6 +439,21 @@ class Post
|
|||
return self::selectView('post-thread-view', $selected, $condition, $params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Select rows from the post-thread-origin-view view
|
||||
*
|
||||
* @param array $selected Array of selected fields, empty for all
|
||||
* @param array $condition Array of fields for condition
|
||||
* @param array $params Array of several parameters
|
||||
*
|
||||
* @return boolean|object
|
||||
* @throws \Exception
|
||||
*/
|
||||
public static function selectOriginThread(array $selected = [], array $condition = [], array $params = [])
|
||||
{
|
||||
return self::selectView('post-thread-origin-view', $selected, $condition, $params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Select rows from the given view for a given user
|
||||
*
|
||||
|
@ -513,6 +543,11 @@ class Post
|
|||
return self::selectViewForUser('post-timeline-view', $uid, $selected, $condition, $params);
|
||||
}
|
||||
|
||||
public static function selectLocalTimelineForUser(int $uid, array $selected = [], array $condition = [], array $params = [])
|
||||
{
|
||||
return self::selectViewForUser('post-timeline-origin-view', $uid, $selected, $condition, $params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Select rows from the post-thread-user-view view for a given user
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue