siteactivity.inc in Heartbeat 6.4
File
modules/heartbeat_example/siteactivity.inc
View source
<?php
heartbeat_include('HeartbeatAccess');
class SiteActivity extends HeartbeatAccess {
protected function hasAccess() {
return TRUE;
}
public function dressUpMessages(HeartbeatParser $heartbeat) {
$sql = " AND ua.access > 0 ";
$heartbeat->raw_messages = $this
->resultSql($sql);
return $heartbeat;
}
public function addViewQuery(&$view) {
$field = "{$view->table_alias}.{$view->real_field}";
$view->query
->add_where('andgroup', "{$field} > %d AND {$view->table_alias}.access > 0", 0);
}
}
Classes
Name |
Description |
SiteActivity |
Class SiteActivity
Concrete class to prepare messages for whole site,
to be customized UI wise |