include right files, fix fulltext index

This commit is contained in:
Uwe Steinmann 2021-02-23 20:37:14 +01:00
parent 2bc678bc7b
commit 9e6f49598d
2 changed files with 8 additions and 12 deletions

View File

@ -24,9 +24,9 @@ include("../inc/inc.Init.php");
include("../inc/inc.Extension.php"); include("../inc/inc.Extension.php");
include("../inc/inc.DBInit.php"); include("../inc/inc.DBInit.php");
include("../inc/inc.ClassNotificationService.php"); include("../inc/inc.ClassNotificationService.php");
//include("../inc/inc.ClassEmailNotify.php"); include("../inc/inc.ClassEmailNotify.php");
include("../inc/inc.Notification.php");
include("../inc/inc.ClassController.php"); include("../inc/inc.ClassController.php");
//include("Log.php");
$notifier = new SeedDMS_NotificationService($logger); $notifier = new SeedDMS_NotificationService($logger);

View File

@ -429,7 +429,10 @@ class HTTP_WebDAV_Server_SeedDMS extends HTTP_WebDAV_Server
} else { } else {
$info["props"][] = $this->mkprop("getcontenttype", "application/x-non-readable"); $info["props"][] = $this->mkprop("getcontenttype", "application/x-non-readable");
} }
if(file_exists($this->dms->contentDir.'/'.$fspath))
$info["props"][] = $this->mkprop("getcontentlength", filesize($this->dms->contentDir.'/'.$fspath)); $info["props"][] = $this->mkprop("getcontentlength", filesize($this->dms->contentDir.'/'.$fspath));
else
$info["props"][] = $this->mkprop("getcontentlength", 0);
if($keywords = $obj->getKeywords()) if($keywords = $obj->getKeywords())
$info["props"][] = $this->mkprop("SeedDMS:", "keywords", $keywords); $info["props"][] = $this->mkprop("SeedDMS:", "keywords", $keywords);
$info["props"][] = $this->mkprop("SeedDMS:", "id", $obj->getID()); $info["props"][] = $this->mkprop("SeedDMS:", "id", $obj->getID());
@ -790,19 +793,12 @@ class HTTP_WebDAV_Server_SeedDMS extends HTTP_WebDAV_Server
} }
*/ */
if($settings->_enableFullSearch) {
$index = $indexconf['Indexer']::open($settings->_luceneDir);
$indexconf['Indexer']::init($settings->_stopWordsFile);
} else {
$index = null;
$indexconf = null;
}
$controller = Controller::factory('AddDocument'); $controller = Controller::factory('AddDocument');
$controller->setParam('dms', $this->dms); $controller->setParam('dms', $this->dms);
$controller->setParam('user', $this->user); $controller->setParam('user', $this->user);
$controller->setParam('documentsource', 'webdav'); $controller->setParam('documentsource', 'webdav');
$controller->setParam('folder', $folder); $controller->setParam('folder', $folder);
$controller->setParam('fulltextservice', $fulltextservice);
$controller->setParam('index', $index); $controller->setParam('index', $index);
$controller->setParam('indexconf', $indexconf); $controller->setParam('indexconf', $indexconf);
$controller->setParam('name', $name); $controller->setParam('name', $name);