From cf0a84b85e16022178a39f09e8fad30e909a4d7c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Mummert?= Date: Mon, 5 Jan 2026 10:29:09 +0100 Subject: [PATCH] add last_seen --- src/Resources/contao/dca/tl_search_pdf.php | 23 +++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/src/Resources/contao/dca/tl_search_pdf.php b/src/Resources/contao/dca/tl_search_pdf.php index 47c0c88..ef174d5 100644 --- a/src/Resources/contao/dca/tl_search_pdf.php +++ b/src/Resources/contao/dca/tl_search_pdf.php @@ -7,11 +7,12 @@ $GLOBALS['TL_DCA']['tl_search_pdf'] = [ 'dataContainer' => DC_Table::class, 'sql' => [ 'keys' => [ - 'id' => 'primary', - 'checksum' => 'unique', - 'page_id' => 'index', - 'url' => 'index', - 'type' => 'index', // ⬅️ NEU + 'id' => 'primary', + 'checksum' => 'unique', + 'page_id' => 'index', + 'url' => 'index', + 'type' => 'index', + 'last_seen' => 'index', // ⬅️ NEU (für Cleanup-Performance) ], ], ], @@ -25,10 +26,18 @@ $GLOBALS['TL_DCA']['tl_search_pdf'] = [ 'sql' => "int(10) unsigned NOT NULL default 0", ], + /* + * Zeitpunkt, wann die Datei zuletzt beim Crawl gesehen wurde + * → Basis für Cleanup + */ + 'last_seen' => [ // ⬅️ NEU + 'sql' => "int(10) unsigned NOT NULL default 0", + ], + /* * Dateityp: pdf | docx | xlsx | pptx */ - 'type' => [ // ⬅️ NEU + 'type' => [ 'sql' => "varchar(16) NOT NULL default 'pdf'", ], @@ -64,7 +73,7 @@ $GLOBALS['TL_DCA']['tl_search_pdf'] = [ /* * Herkunftsseite (tl_page.id) - * → Cleanup / Referenz + * → optional, Debug / Referenz */ 'page_id' => [ 'sql' => "int(10) unsigned NOT NULL default 0",