From 8ca6cc32b2c789a3149861159ad258f2cb9491e3 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 14:39:39 +0200 Subject: Adding upstream version 2.11.4. Signed-off-by: Daniel Baumann --- .../Ido/Query/HostcommentdeletionhistoryQuery.php | 44 ++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcommentdeletionhistoryQuery.php (limited to 'modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcommentdeletionhistoryQuery.php') diff --git a/modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcommentdeletionhistoryQuery.php b/modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcommentdeletionhistoryQuery.php new file mode 100644 index 0000000..d798d56 --- /dev/null +++ b/modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcommentdeletionhistoryQuery.php @@ -0,0 +1,44 @@ +getColumn() === 'timestamp') { + $this->requireColumn('timestamp'); + $filter->setColumn('hch.deletion_time'); + $filter->setExpression($this->timestampForSql($this->valueToTimestamp($filter->getExpression()))); + return null; + } + + return parent::requireFilterColumns($filter); + } + + /** + * {@inheritdoc} + */ + protected function joinBaseTables() + { + parent::joinBaseTables(); + $this->select->where("hch.deletion_time > '1970-01-02 00:00:00'"); + $this->columnMap['commenthistory']['timestamp'] = str_replace( + 'comment_time', + 'deletion_time', + $this->columnMap['commenthistory']['timestamp'] + ); + $this->columnMap['commenthistory']['type'] = str_replace( + 'END)', + "END || '_deleted')", + $this->columnMap['commenthistory']['type'] + ); + } +} -- cgit v1.2.3