This commit is contained in:
Dennis Eichhorn 2023-09-24 20:30:26 +00:00
commit 2685e69651
2 changed files with 10 additions and 10 deletions

View File

@ -88,7 +88,7 @@ final class BackendController extends Controller
ORDER BY date ASC;' ORDER BY date ASC;'
); );
$view->data['stats']['impressions'] = $query->execute()?->fetchAll(\PDO::FETCH_COLUMN|\PDO::FETCH_GROUP) ?? []; $view->data['stats']['impressions'] = $query->execute()?->fetchAll(\PDO::FETCH_COLUMN | \PDO::FETCH_GROUP) ?? [];
$query = new Builder($this->app->dbPool->get()); $query = new Builder($this->app->dbPool->get());
$query->raw( $query->raw(
@ -116,7 +116,7 @@ final class BackendController extends Controller
GROUP BY monitoring_request_agent;' GROUP BY monitoring_request_agent;'
); );
$view->data['stats']['browser'] = $query->execute()?->fetchAll(\PDO::FETCH_COLUMN|\PDO::FETCH_GROUP) ?? []; $view->data['stats']['browser'] = $query->execute()?->fetchAll(\PDO::FETCH_COLUMN | \PDO::FETCH_GROUP) ?? [];
$query = new Builder($this->app->dbPool->get()); $query = new Builder($this->app->dbPool->get());
$query->raw( $query->raw(

View File

@ -37,14 +37,14 @@ final class ImpressionStatMapper extends DataMapperFactory
*/ */
public const COLUMNS = [ public const COLUMNS = [
'monitoring_request_id' => ['name' => 'monitoring_request_id', 'type' => 'int', 'internal' => 'id'], 'monitoring_request_id' => ['name' => 'monitoring_request_id', 'type' => 'int', 'internal' => 'id'],
'monitoring_request_host' => ['name' => 'monitoring_request_host', 'type' => 'string', 'internal' => 'host',], 'monitoring_request_host' => ['name' => 'monitoring_request_host', 'type' => 'string', 'internal' => 'host',],
'monitoring_request_language' => ['name' => 'monitoring_request_language', 'type' => 'string', 'internal' => 'language',], 'monitoring_request_language' => ['name' => 'monitoring_request_language', 'type' => 'string', 'internal' => 'language',],
'monitoring_request_country' => ['name' => 'monitoring_request_country', 'type' => 'string', 'internal' => 'country',], 'monitoring_request_country' => ['name' => 'monitoring_request_country', 'type' => 'string', 'internal' => 'country',],
'monitoring_request_path' => ['name' => 'monitoring_request_path', 'type' => 'string', 'internal' => 'path',], 'monitoring_request_path' => ['name' => 'monitoring_request_path', 'type' => 'string', 'internal' => 'path',],
'monitoring_request_uri' => ['name' => 'monitoring_request_uri', 'type' => 'string', 'internal' => 'uri',], 'monitoring_request_uri' => ['name' => 'monitoring_request_uri', 'type' => 'string', 'internal' => 'uri',],
'monitoring_request_referer' => ['name' => 'monitoring_request_referer', 'type' => 'string', 'internal' => 'referer',], 'monitoring_request_referer' => ['name' => 'monitoring_request_referer', 'type' => 'string', 'internal' => 'referer',],
'monitoring_request_agent' => ['name' => 'monitoring_request_agent', 'type' => 'string', 'internal' => 'userAgent',], 'monitoring_request_agent' => ['name' => 'monitoring_request_agent', 'type' => 'string', 'internal' => 'userAgent',],
'monitoring_request_datetime' => ['name' => 'monitoring_request_datetime', 'type' => 'DateTime', 'internal' => 'datetime',], 'monitoring_request_datetime' => ['name' => 'monitoring_request_datetime', 'type' => 'DateTime', 'internal' => 'datetime',],
]; ];
/** /**