2017-04-22 11:22:54 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace SilverStripe\FullTextSearch\Captures;
|
|
|
|
|
|
|
|
use SilverStripe\PostgreSQL\PostgreSQLDatabase;
|
|
|
|
use SilverStripe\FullTextSearch\Search\Updaters\SearchUpdater;
|
|
|
|
|
2017-11-30 02:43:17 +01:00
|
|
|
if (!class_exists(PostgreSQLDatabase::class)) {
|
2017-04-22 11:22:54 +02:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2017-11-14 21:48:52 +01:00
|
|
|
class SearchManipulateCapture_PostgreSQLDatabase extends PostgreSQLDatabase
|
|
|
|
{
|
2017-04-22 11:22:54 +02:00
|
|
|
public $isManipulationCapture = true;
|
|
|
|
|
2017-11-14 21:48:52 +01:00
|
|
|
public function manipulate($manipulation)
|
|
|
|
{
|
2017-04-22 11:22:54 +02:00
|
|
|
$res = parent::manipulate($manipulation);
|
|
|
|
SearchUpdater::handle_manipulation($manipulation);
|
|
|
|
return $res;
|
|
|
|
}
|
|
|
|
}
|