@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | public function addFormatAction() |
| 159 | 159 | { |
| 160 | 160 | // Include formats definition file. |
| 161 | - $formatsDefaults = include(ExtensionManagementUtility::extPath('dlf') . 'Resources/Private/Data/FormatDefaults.php'); |
|
| 161 | + $formatsDefaults = include(ExtensionManagementUtility::extPath('dlf').'Resources/Private/Data/FormatDefaults.php'); |
|
| 162 | 162 | |
| 163 | 163 | $frameworkConfiguration = $this->configurationManager->getConfiguration($this->configurationManager::CONFIGURATION_TYPE_FRAMEWORK); |
| 164 | 164 | // tx_dlf_formats are stored on PID = 0 |
@@ -196,7 +196,7 @@ discard block |
||
| 196 | 196 | public function addMetadataAction() |
| 197 | 197 | { |
| 198 | 198 | // Include metadata definition file. |
| 199 | - $metadataDefaults = include(ExtensionManagementUtility::extPath('dlf') . 'Resources/Private/Data/MetadataDefaults.php'); |
|
| 199 | + $metadataDefaults = include(ExtensionManagementUtility::extPath('dlf').'Resources/Private/Data/MetadataDefaults.php'); |
|
| 200 | 200 | |
| 201 | 201 | $doPersist = false; |
| 202 | 202 | |
@@ -208,7 +208,7 @@ discard block |
||
| 208 | 208 | if ($this->metadataRepository->findOneByIndexName($indexName) === null) { |
| 209 | 209 | |
| 210 | 210 | $newRecord = GeneralUtility::makeInstance(Metadata::class); |
| 211 | - $newRecord->setLabel($this->getLLL('metadata.' . $indexName, $this->siteLanguages[0]->getTypo3Language(), $metadataLabels)); |
|
| 211 | + $newRecord->setLabel($this->getLLL('metadata.'.$indexName, $this->siteLanguages[0]->getTypo3Language(), $metadataLabels)); |
|
| 212 | 212 | $newRecord->setIndexName($indexName); |
| 213 | 213 | $newRecord->setDefaultValue($values['default_value']); |
| 214 | 214 | $newRecord->setWrap($values['wrap'] ? : $GLOBALS['TCA']['tx_dlf_metadata']['columns']['wrap']['config']['default']); |
@@ -243,7 +243,7 @@ discard block |
||
| 243 | 243 | $translatedRecord = GeneralUtility::makeInstance(Metadata::class); |
| 244 | 244 | $translatedRecord->setL18nParent($newRecord); |
| 245 | 245 | $translatedRecord->_setProperty('_languageUid', $siteLanguage->getLanguageId()); |
| 246 | - $translatedRecord->setLabel($this->getLLL('metadata.' . $indexName, $siteLanguage->getTypo3Language(), $metadataLabels)); |
|
| 246 | + $translatedRecord->setLabel($this->getLLL('metadata.'.$indexName, $siteLanguage->getTypo3Language(), $metadataLabels)); |
|
| 247 | 247 | $translatedRecord->setIndexName($indexName); |
| 248 | 248 | $translatedRecord->setWrap($newRecord->getWrap()); |
| 249 | 249 | |
@@ -277,7 +277,7 @@ discard block |
||
| 277 | 277 | |
| 278 | 278 | if ($this->solrCoreRepository->findOneByPid($this->pid) === null) { |
| 279 | 279 | $newRecord = GeneralUtility::makeInstance(SolrCore::class); |
| 280 | - $newRecord->setLabel($this->getLLL('flexform.solrcore', $this->siteLanguages[0]->getTypo3Language(), $beLabels). ' (PID ' . $this->pid . ')'); |
|
| 280 | + $newRecord->setLabel($this->getLLL('flexform.solrcore', $this->siteLanguages[0]->getTypo3Language(), $beLabels).' (PID '.$this->pid.')'); |
|
| 281 | 281 | $indexName = Solr::createCore(''); |
| 282 | 282 | $newRecord->setIndexName($indexName); |
| 283 | 283 | |
@@ -301,7 +301,7 @@ discard block |
||
| 301 | 301 | public function addStructureAction() |
| 302 | 302 | { |
| 303 | 303 | // Include structure definition file. |
| 304 | - $structureDefaults = include(ExtensionManagementUtility::extPath('dlf') . 'Resources/Private/Data/StructureDefaults.php'); |
|
| 304 | + $structureDefaults = include(ExtensionManagementUtility::extPath('dlf').'Resources/Private/Data/StructureDefaults.php'); |
|
| 305 | 305 | |
| 306 | 306 | $doPersist = false; |
| 307 | 307 | |
@@ -312,7 +312,7 @@ discard block |
||
| 312 | 312 | // if default format record is not found, add it to the repository |
| 313 | 313 | if ($this->structureRepository->findOneByIndexName($indexName) === null) { |
| 314 | 314 | $newRecord = GeneralUtility::makeInstance(Structure::class); |
| 315 | - $newRecord->setLabel($this->getLLL('structure.' . $indexName, $this->siteLanguages[0]->getTypo3Language(), $structLabels)); |
|
| 315 | + $newRecord->setLabel($this->getLLL('structure.'.$indexName, $this->siteLanguages[0]->getTypo3Language(), $structLabels)); |
|
| 316 | 316 | $newRecord->setIndexName($indexName); |
| 317 | 317 | $newRecord->setToplevel($values['toplevel']); |
| 318 | 318 | $newRecord->setOaiName($values['oai_name']); |
@@ -326,7 +326,7 @@ discard block |
||
| 326 | 326 | $translatedRecord = GeneralUtility::makeInstance(Structure::class); |
| 327 | 327 | $translatedRecord->setL18nParent($newRecord); |
| 328 | 328 | $translatedRecord->_setProperty('_languageUid', $siteLanguage->getLanguageId()); |
| 329 | - $translatedRecord->setLabel($this->getLLL('structure.' . $indexName, $siteLanguage->getTypo3Language(), $structLabels)); |
|
| 329 | + $translatedRecord->setLabel($this->getLLL('structure.'.$indexName, $siteLanguage->getTypo3Language(), $structLabels)); |
|
| 330 | 330 | $translatedRecord->setIndexName($indexName); |
| 331 | 331 | |
| 332 | 332 | $this->structureRepository->add($translatedRecord); |
@@ -378,15 +378,15 @@ discard block |
||
| 378 | 378 | $this->forward('error'); |
| 379 | 379 | } |
| 380 | 380 | |
| 381 | - $formatsDefaults = include(ExtensionManagementUtility::extPath('dlf') . 'Resources/Private/Data/FormatDefaults.php'); |
|
| 381 | + $formatsDefaults = include(ExtensionManagementUtility::extPath('dlf').'Resources/Private/Data/FormatDefaults.php'); |
|
| 382 | 382 | $recordInfos['formats']['numCurrent'] = $this->formatRepository->countAll(); |
| 383 | 383 | $recordInfos['formats']['numDefault'] = count($formatsDefaults); |
| 384 | 384 | |
| 385 | - $structuresDefaults = include(ExtensionManagementUtility::extPath('dlf') . 'Resources/Private/Data/StructureDefaults.php'); |
|
| 385 | + $structuresDefaults = include(ExtensionManagementUtility::extPath('dlf').'Resources/Private/Data/StructureDefaults.php'); |
|
| 386 | 386 | $recordInfos['structures']['numCurrent'] = $this->structureRepository->countByPid($this->pid); |
| 387 | 387 | $recordInfos['structures']['numDefault'] = count($structuresDefaults); |
| 388 | 388 | |
| 389 | - $metadataDefaults = include(ExtensionManagementUtility::extPath('dlf') . 'Resources/Private/Data/MetadataDefaults.php'); |
|
| 389 | + $metadataDefaults = include(ExtensionManagementUtility::extPath('dlf').'Resources/Private/Data/MetadataDefaults.php'); |
|
| 390 | 390 | $recordInfos['metadata']['numCurrent'] = $this->metadataRepository->countByPid($this->pid); |
| 391 | 391 | $recordInfos['metadata']['numDefault'] = count($metadataDefaults); |
| 392 | 392 | |
@@ -120,7 +120,7 @@ |
||
| 120 | 120 | */ |
| 121 | 121 | private function getQuery($fields, $parameters) |
| 122 | 122 | { |
| 123 | - return $fields['fulltext'] . ':(' . Solr::escapeQuery((string) $parameters['q']) . ') AND ' . $fields['uid'] . ':' . $this->getUid($parameters['uid']); |
|
| 123 | + return $fields['fulltext'].':('.Solr::escapeQuery((string) $parameters['q']).') AND '.$fields['uid'].':'.$this->getUid($parameters['uid']); |
|
| 124 | 124 | } |
| 125 | 125 | |
| 126 | 126 | /** |
@@ -45,7 +45,7 @@ |
||
| 45 | 45 | $parameters = $request->getParsedBody(); |
| 46 | 46 | $solrCore = (string) $parameters['solrcore']; |
| 47 | 47 | $uHash = (string) $parameters['uHash']; |
| 48 | - if (hash_equals(GeneralUtility::hmac((string) (new Typo3Version()) . Environment::getExtensionsPath(), 'SearchSuggest'), $uHash) === false) { |
|
| 48 | + if (hash_equals(GeneralUtility::hmac((string) (new Typo3Version()).Environment::getExtensionsPath(), 'SearchSuggest'), $uHash) === false) { |
|
| 49 | 49 | throw new \InvalidArgumentException('No valid parameter passed!', 1580585079); |
| 50 | 50 | } |
| 51 | 51 | // Perform Solr query. |
@@ -65,22 +65,22 @@ |
||
| 65 | 65 | $_EXTKEY = 'dlf'; |
| 66 | 66 | // Register tools for toolbox plugin. |
| 67 | 67 | $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'] = []; |
| 68 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_fulltexttool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.fulltexttool'; |
|
| 69 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_annotationtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.annotationtool'; |
|
| 70 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_fulltextdownloadtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.fulltextdownloadtool'; |
|
| 71 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_imagedownloadtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.imagedownloadtool'; |
|
| 72 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_imagemanipulationtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.imagemanipulationtool'; |
|
| 73 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_pdfdownloadtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.pdfdownloadtool'; |
|
| 74 | -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY) . '_searchindocumenttool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.searchindocumenttool'; |
|
| 68 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_fulltexttool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.fulltexttool'; |
|
| 69 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_annotationtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.annotationtool'; |
|
| 70 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_fulltextdownloadtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.fulltextdownloadtool'; |
|
| 71 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_imagedownloadtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.imagedownloadtool'; |
|
| 72 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_imagemanipulationtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.imagemanipulationtool'; |
|
| 73 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_pdfdownloadtool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.pdfdownloadtool'; |
|
| 74 | +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Plugin/Toolbox.php']['tools'][\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getCN($_EXTKEY).'_searchindocumenttool'] = 'LLL:EXT:dlf/Resources/Private/Language/Labels.xml:tx_dlf_toolbox.searchindocumenttool'; |
|
| 75 | 75 | // Register hooks. |
| 76 | 76 | $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processDatamapClass'][] = \Kitodo\Dlf\Hooks\DataHandler::class; |
| 77 | 77 | $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processCmdmapClass'][] = \Kitodo\Dlf\Hooks\DataHandler::class; |
| 78 | 78 | $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['dlf/Classes/Common/MetsDocument.php']['hookClass'][] = \Kitodo\Dlf\Hooks\KitodoProductionHacks::class; |
| 79 | 79 | // Register AJAX eID handlers. |
| 80 | -$GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_dlf_search_suggest'] = \Kitodo\Dlf\Eid\SearchSuggest::class . '::main'; |
|
| 81 | -$GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_dlf_search_in_document'] = \Kitodo\Dlf\Eid\SearchInDocument::class . '::main'; |
|
| 80 | +$GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_dlf_search_suggest'] = \Kitodo\Dlf\Eid\SearchSuggest::class.'::main'; |
|
| 81 | +$GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_dlf_search_in_document'] = \Kitodo\Dlf\Eid\SearchInDocument::class.'::main'; |
|
| 82 | 82 | if ($GLOBALS['TYPO3_CONF_VARS']['EXTENSIONS']['dlf']['enableInternalProxy'] ?? false) { |
| 83 | - $GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_dlf_pageview_proxy'] = \Kitodo\Dlf\Eid\PageViewProxy::class . '::main'; |
|
| 83 | + $GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_dlf_pageview_proxy'] = \Kitodo\Dlf\Eid\PageViewProxy::class.'::main'; |
|
| 84 | 84 | } |
| 85 | 85 | // Use Caching Framework for Solr queries |
| 86 | 86 | if (!is_array($GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['tx_dlf_solr'])) { |