From 0186e1af00799133504df6fac0f661c6a4493f56 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Thu, 15 Dec 2022 12:36:35 +0100 Subject: [PATCH] check field indexed instead of created --- views/bootstrap/class.Indexer.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/views/bootstrap/class.Indexer.php b/views/bootstrap/class.Indexer.php index 743e108c6..75dd4200f 100644 --- a/views/bootstrap/class.Indexer.php +++ b/views/bootstrap/class.Indexer.php @@ -42,17 +42,17 @@ class SeedDMS_View_Indexer_Process_Folder { /* {{{ */ if(($this->numdocs == 0) || !($hit = $lucenesearch->getFolder($folder->getId()))) { echo " getID()."\" class=\"indexme indexstatus\" data-docid=\"F".$folder->getID()."\">".getMLText('index_waiting').""; } else { - /* Check if the attribute created is set or has a value older + /* Check if the attribute indexed is set or has a value older * than the lastet content. Documents without such an attribute * where added when a new document was added to the dms. In such * a case the document content wasn't indexed. */ try { - $created = (int) $hit->getDocument()->getFieldValue('created'); + $indexed = (int) $hit->getDocument()->getFieldValue('indexed'); } catch (/* Zend_Search_Lucene_ */Exception $e) { - $created = 0; + $indexed = 0; } - if($created >= $folder->getDate() && !$this->forceupdate) { + if($indexed >= $folder->getDate() && !$this->forceupdate) { echo "getID()."\" class=\"indexstatus\" data-docid=\"F".$folder->getID()."\">".getMLText('index_document_unchanged').""; } else { $this->fulltextservice->Indexer()->delete($hit->id); @@ -70,18 +70,18 @@ class SeedDMS_View_Indexer_Process_Folder { /* {{{ */ if(($this->numdocs == 0) || !($hit = $lucenesearch->getDocument($document->getId()))) { echo " getID()."\" class=\"indexme indexstatus\" data-docid=\"D".$document->getID()."\">".getMLText('index_waiting').""; } else { - /* Check if the attribute created is set or has a value older + /* Check if the attribute indexed is set or has a value older * than the lastet content. Documents without such an attribute * where added when a new document was added to the dms. In such * a case the document content wasn't indexed. */ try { - $created = (int) $hit->getDocument()->getFieldValue('created'); + $indexed = (int) $hit->getDocument()->getFieldValue('indexed'); } catch (/* Zend_Search_Lucene_ */Exception $e) { - $created = 0; + $indexed = 0; } $content = $document->getLatestContent(); - if($created >= $content->getDate() && !$this->forceupdate) { + if($indexed >= $content->getDate() && !$this->forceupdate) { echo "getID()."\" class=\"indexstatus\" data-docid=\"D".$document->getID()."\">".getMLText('index_document_unchanged').""; } else { $this->fulltextservice->Indexer()->delete($hit->id);