function views_plugin_row_heartbeat_rss::pre_render in Heartbeat 7
Allow the style to do stuff before each row is rendered.
Parameters
array $result: The full array of results from the query.
Overrides views_plugin_row::pre_render
File
- views/
views_plugin_row_heartbeat_rss.inc, line 63 - Contains the heartbeat activity view row style plugin.
Class
- views_plugin_row_heartbeat_rss
- Plugin which performs a heartbeat_activity_view on the resulting object.
Code
function pre_render($values) {
$uaids = array();
foreach ($values as $row) {
$uaids[] = $row->{$this->field_alias};
}
// We create a stream, however the query does not need to run since
// views took care of that part. By creating a stream we can provide
// the general flow to display everything.
if ($heartbeatStream = heartbeat_stream('viewsactivity', $this->display->display_plugin == 'page', $GLOBALS['user'])) {
if (isset($this->view->query->limit)) {
$heartbeatStream->config->num_load_max = $this->view->query->limit;
}
$this->activities = heartbeat_stream_views_build($heartbeatStream, $uaids);
$this->stream = $heartbeatStream;
}
}