HostnotificationQuery: Apply query optimization from NotificationhistoryQuery
refs #9009
This commit is contained in:
parent
b235bb6982
commit
f9948f5513
|
@ -65,6 +65,18 @@ class HostnotificationQuery extends IdoQuery
|
|||
)
|
||||
);
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function whereToSql($col, $sign, $expression)
|
||||
{
|
||||
if ($col === 'UNIX_TIMESTAMP(hn.start_time)') {
|
||||
return 'hn.start_time ' . $sign . ' ' . $this->timestampForSql($this->valueToTimestamp($expression));
|
||||
} else {
|
||||
return parent::whereToSql($col, $sign, $expression);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
|
|
Loading…
Reference in New Issue