@@ -22,12 +22,12 @@ |
||
| 22 | 22 | * Handle CMD. |
| 23 | 23 | */ |
| 24 | 24 | public function processCmdmap_postProcess( |
| 25 | - int|string $command, |
|
| 25 | + int | string $command, |
|
| 26 | 26 | string $table, |
| 27 | - int|string $uid, |
|
| 27 | + int | string $uid, |
|
| 28 | 28 | mixed $value, |
| 29 | 29 | DataHandler $handler, |
| 30 | - false|array $pasteUpdate, |
|
| 30 | + false | array $pasteUpdate, |
|
| 31 | 31 | array $pasteDatamap |
| 32 | 32 | ): void { |
| 33 | 33 | /** @var IndexerService $indexer */ |
@@ -25,7 +25,7 @@ |
||
| 25 | 25 | public function processDatamap_afterDatabaseOperations( |
| 26 | 26 | string $status, |
| 27 | 27 | string $table, |
| 28 | - int|string $identifier, |
|
| 28 | + int | string $identifier, |
|
| 29 | 29 | array $fieldArray, |
| 30 | 30 | DataHandler $dataHandler |
| 31 | 31 | ): void { |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | /** |
| 41 | 41 | * Calendarize indexer for ke_search. |
| 42 | 42 | */ |
| 43 | - public function customIndexer(array &$indexerConfig, IndexerRunner &$indexerObject): string |
|
| 43 | + public function customIndexer(array &$indexerConfig, IndexerRunner & $indexerObject): string |
|
| 44 | 44 | { |
| 45 | 45 | if (self::KEY !== $indexerConfig['type']) { |
| 46 | 46 | return ''; |
@@ -103,21 +103,21 @@ discard block |
||
| 103 | 103 | ], '&'); |
| 104 | 104 | |
| 105 | 105 | $storeArguments = [ |
| 106 | - $indexerConfig['storagepid'], // storage PID |
|
| 107 | - $title, // record title |
|
| 108 | - self::KEY, // content type |
|
| 109 | - $indexerConfig['targetpid'], // target PID: where is the single view? |
|
| 106 | + $indexerConfig['storagepid'], // storage PID |
|
| 107 | + $title, // record title |
|
| 108 | + self::KEY, // content type |
|
| 109 | + $indexerConfig['targetpid'], // target PID: where is the single view? |
|
| 110 | 110 | // indexed content, includes the title (linebreak after title) |
| 111 | 111 | $fullContent, |
| 112 | - $originalObject->getKeSearchTags($index), // tags for faceted search |
|
| 113 | - $params, // typolink params for singleview |
|
| 114 | - $abstract, // abstract; shown in result list if not empty |
|
| 115 | - $row[$languageField], // language uid |
|
| 116 | - $row['starttime'], // starttime |
|
| 117 | - $row['endtime'], // endtime |
|
| 118 | - $row['fe_group'], // fe_group |
|
| 119 | - false, // debug only? |
|
| 120 | - $additionalFields, // additionalFields |
|
| 112 | + $originalObject->getKeSearchTags($index), // tags for faceted search |
|
| 113 | + $params, // typolink params for singleview |
|
| 114 | + $abstract, // abstract; shown in result list if not empty |
|
| 115 | + $row[$languageField], // language uid |
|
| 116 | + $row['starttime'], // starttime |
|
| 117 | + $row['endtime'], // endtime |
|
| 118 | + $row['fe_group'], // fe_group |
|
| 119 | + false, // debug only? |
|
| 120 | + $additionalFields, // additionalFields |
|
| 121 | 121 | ]; |
| 122 | 122 | |
| 123 | 123 | $indexerObject->storeInIndex(...$storeArguments); |
@@ -50,7 +50,7 @@ |
||
| 50 | 50 | $connection = $connectionPool->getConnectionByName(ConnectionPool::DEFAULT_CONNECTION_NAME); |
| 51 | 51 | $dbSchema = $connection->createSchemaManager()->introspectSchema(); |
| 52 | 52 | |
| 53 | - $tableNames = array_map(static function ($table) { |
|
| 53 | + $tableNames = array_map(static function($table) { |
|
| 54 | 54 | return $table->getName(); |
| 55 | 55 | }, $dbSchema->getTables()); |
| 56 | 56 | |
@@ -115,7 +115,7 @@ |
||
| 115 | 115 | return array_values( |
| 116 | 116 | array_filter( |
| 117 | 117 | $result, |
| 118 | - static function ($item) { |
|
| 118 | + static function($item) { |
|
| 119 | 119 | return is_array($item) && VersionState::DELETE_PLACEHOLDER !== ($item['t3ver_state'] ?? false); |
| 120 | 120 | } |
| 121 | 121 | ) |
@@ -14,7 +14,7 @@ |
||
| 14 | 14 | /** |
| 15 | 15 | * Find by Index UIDs. |
| 16 | 16 | */ |
| 17 | - public function findByUids(array $uids): array|QueryResultInterface |
|
| 17 | + public function findByUids(array $uids): array | QueryResultInterface |
|
| 18 | 18 | { |
| 19 | 19 | $query = $this->createQuery(); |
| 20 | 20 | |
@@ -78,7 +78,7 @@ discard block |
||
| 78 | 78 | OptionRequest $options, |
| 79 | 79 | array $allowedPages = [], |
| 80 | 80 | bool $ignoreEnableFields = true |
| 81 | - ): array|QueryResultInterface { |
|
| 81 | + ): array | QueryResultInterface { |
|
| 82 | 82 | $query = $this->createQuery(); |
| 83 | 83 | $querySettings = $query->getQuerySettings(); |
| 84 | 84 | $querySettings->setIgnoreEnableFields($ignoreEnableFields); |
@@ -138,12 +138,12 @@ discard block |
||
| 138 | 138 | */ |
| 139 | 139 | public function findList( |
| 140 | 140 | int $limit = 0, |
| 141 | - int|string $listStartTime = 0, |
|
| 141 | + int | string $listStartTime = 0, |
|
| 142 | 142 | int $startOffsetHours = 0, |
| 143 | 143 | int $overrideStartDate = 0, |
| 144 | 144 | int $overrideEndDate = 0, |
| 145 | 145 | bool $ignoreStoragePid = false |
| 146 | - ): array|QueryResultInterface { |
|
| 146 | + ): array | QueryResultInterface { |
|
| 147 | 147 | $startTime = DateTimeUtility::getNow(); |
| 148 | 148 | $endTime = null; |
| 149 | 149 | |
@@ -184,7 +184,7 @@ discard block |
||
| 184 | 184 | \DateTimeInterface $endDate = null, |
| 185 | 185 | array $customSearch = [], |
| 186 | 186 | int $limit = 0 |
| 187 | - ): array|QueryResultInterface { |
|
| 187 | + ): array | QueryResultInterface { |
|
| 188 | 188 | $event = new IndexRepositoryFindBySearchEvent($startDate, $endDate, $customSearch, $this->indexTypes, false); |
| 189 | 189 | $this->eventDispatcher->dispatch($event); |
| 190 | 190 | |
@@ -269,7 +269,7 @@ discard block |
||
| 269 | 269 | /** |
| 270 | 270 | * Find Past Events. |
| 271 | 271 | */ |
| 272 | - public function findByPast(int $limit, string $sort, string $listStartTime = '0'): array|QueryResultInterface |
|
| 272 | + public function findByPast(int $limit, string $sort, string $listStartTime = '0'): array | QueryResultInterface |
|
| 273 | 273 | { |
| 274 | 274 | $now = DateTimeUtility::getNow(); |
| 275 | 275 | if ('now' !== $listStartTime) { |
@@ -295,7 +295,7 @@ discard block |
||
| 295 | 295 | /** |
| 296 | 296 | * Find by Index UIDs. |
| 297 | 297 | */ |
| 298 | - public function findByUids(array $uids): array|QueryResultInterface |
|
| 298 | + public function findByUids(array $uids): array | QueryResultInterface |
|
| 299 | 299 | { |
| 300 | 300 | $query = $this->createQuery(); |
| 301 | 301 | $query->setOrderings($this->getSorting(QueryInterface::ORDER_ASCENDING)); |
@@ -316,7 +316,7 @@ discard block |
||
| 316 | 316 | int $limit = 100, |
| 317 | 317 | string $sort = QueryInterface::ORDER_ASCENDING, |
| 318 | 318 | bool $useIndexTime = false |
| 319 | - ): array|QueryResultInterface { |
|
| 319 | + ): array | QueryResultInterface { |
|
| 320 | 320 | if (!$future && !$past) { |
| 321 | 321 | return []; |
| 322 | 322 | } |
@@ -340,8 +340,7 @@ discard block |
||
| 340 | 340 | |
| 341 | 341 | $query->setLimit($limit); |
| 342 | 342 | $sort = QueryInterface::ORDER_ASCENDING === $sort ? |
| 343 | - QueryInterface::ORDER_ASCENDING : |
|
| 344 | - QueryInterface::ORDER_DESCENDING; |
|
| 343 | + QueryInterface::ORDER_ASCENDING : QueryInterface::ORDER_DESCENDING; |
|
| 345 | 344 | $query->setOrderings($this->getSorting($sort)); |
| 346 | 345 | |
| 347 | 346 | return $this->matchAndExecute($query, $constraints); |
@@ -356,7 +355,7 @@ discard block |
||
| 356 | 355 | bool $past = false, |
| 357 | 356 | int $limit = 100, |
| 358 | 357 | string $sort = QueryInterface::ORDER_ASCENDING |
| 359 | - ): array|QueryResultInterface { |
|
| 358 | + ): array | QueryResultInterface { |
|
| 360 | 359 | if (!$future && !$past) { |
| 361 | 360 | return []; |
| 362 | 361 | } |
@@ -384,8 +383,7 @@ discard block |
||
| 384 | 383 | |
| 385 | 384 | $query->setLimit($limit); |
| 386 | 385 | $sort = QueryInterface::ORDER_ASCENDING === $sort ? |
| 387 | - QueryInterface::ORDER_ASCENDING : |
|
| 388 | - QueryInterface::ORDER_DESCENDING; |
|
| 386 | + QueryInterface::ORDER_ASCENDING : QueryInterface::ORDER_DESCENDING; |
|
| 389 | 387 | $query->setOrderings($this->getSorting($sort)); |
| 390 | 388 | |
| 391 | 389 | return $this->matchAndExecute($query, $constraints); |
@@ -394,7 +392,7 @@ discard block |
||
| 394 | 392 | /** |
| 395 | 393 | * find Year. |
| 396 | 394 | */ |
| 397 | - public function findYear(int $year): array|QueryResultInterface |
|
| 395 | + public function findYear(int $year): array | QueryResultInterface |
|
| 398 | 396 | { |
| 399 | 397 | $startTime = (new \DateTimeImmutable('midnight'))->setDate($year, 1, 1); |
| 400 | 398 | $endTime = $startTime->modify('+1 year -1 second'); |
@@ -405,7 +403,7 @@ discard block |
||
| 405 | 403 | /** |
| 406 | 404 | * find quarter. |
| 407 | 405 | */ |
| 408 | - public function findQuarter(int $year, int $quarter): array|QueryResultInterface |
|
| 406 | + public function findQuarter(int $year, int $quarter): array | QueryResultInterface |
|
| 409 | 407 | { |
| 410 | 408 | $startMonth = 1 + (3 * ($quarter - 1)); |
| 411 | 409 | $startTime = (new \DateTimeImmutable('midnight'))->setDate($year, $startMonth, 1); |
@@ -417,7 +415,7 @@ discard block |
||
| 417 | 415 | /** |
| 418 | 416 | * find Month. |
| 419 | 417 | */ |
| 420 | - public function findMonth(int $year, int $month): array|QueryResultInterface |
|
| 418 | + public function findMonth(int $year, int $month): array | QueryResultInterface |
|
| 421 | 419 | { |
| 422 | 420 | $startTime = (new \DateTimeImmutable('midnight'))->setDate($year, $month, 1); |
| 423 | 421 | $endTime = $startTime->modify('+1 month -1 second'); |
@@ -428,7 +426,7 @@ discard block |
||
| 428 | 426 | /** |
| 429 | 427 | * find Week. |
| 430 | 428 | */ |
| 431 | - public function findWeek(int $year, int $week, int $weekStart = 1): array|QueryResultInterface |
|
| 429 | + public function findWeek(int $year, int $week, int $weekStart = 1): array | QueryResultInterface |
|
| 432 | 430 | { |
| 433 | 431 | $startTime = \DateTimeImmutable::createFromMutable( |
| 434 | 432 | DateTimeUtility::convertWeekYear2DayMonthYear($week, $year, $weekStart) |
@@ -441,7 +439,7 @@ discard block |
||
| 441 | 439 | /** |
| 442 | 440 | * find day. |
| 443 | 441 | */ |
| 444 | - public function findDay(int $year, int $month, int $day): array|QueryResultInterface |
|
| 442 | + public function findDay(int $year, int $month, int $day): array | QueryResultInterface |
|
| 445 | 443 | { |
| 446 | 444 | $startTime = (new \DateTimeImmutable('midnight'))->setDate($year, $month, $day); |
| 447 | 445 | $endTime = $startTime->modify('+1 day -1 second'); |
@@ -479,7 +477,7 @@ discard block |
||
| 479 | 477 | public function findByTimeSlot( |
| 480 | 478 | ?\DateTimeInterface $startTime, |
| 481 | 479 | ?\DateTimeInterface $endTime = null |
| 482 | - ): array|QueryResultInterface { |
|
| 480 | + ): array | QueryResultInterface { |
|
| 483 | 481 | $query = $this->createQuery(); |
| 484 | 482 | $constraints = $this->getDefaultConstraints($query); |
| 485 | 483 | $this->addTimeFrameConstraints($constraints, $query, $startTime, $endTime); |
@@ -493,7 +491,7 @@ discard block |
||
| 493 | 491 | /** |
| 494 | 492 | * Find all indices by the given Event model. |
| 495 | 493 | */ |
| 496 | - public function findByEvent(DomainObjectInterface $event): array|QueryResultInterface |
|
| 494 | + public function findByEvent(DomainObjectInterface $event): array | QueryResultInterface |
|
| 497 | 495 | { |
| 498 | 496 | $query = $this->createQuery(); |
| 499 | 497 | |
@@ -521,8 +519,7 @@ discard block |
||
| 521 | 519 | $frameworkConfig = $configurationManager |
| 522 | 520 | ->getConfiguration(ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK); |
| 523 | 521 | return isset($frameworkConfig['persistence']['storagePid']) ? |
| 524 | - GeneralUtility::intExplode(',', $frameworkConfig['persistence']['storagePid']) : |
|
| 525 | - []; |
|
| 522 | + GeneralUtility::intExplode(',', $frameworkConfig['persistence']['storagePid']) : []; |
|
| 526 | 523 | } |
| 527 | 524 | |
| 528 | 525 | /** |
@@ -21,7 +21,7 @@ |
||
| 21 | 21 | /** |
| 22 | 22 | * Check the constraint and execute the query. |
| 23 | 23 | */ |
| 24 | - public function matchAndExecute(QueryInterface $query, array $constraints = []): array|QueryResultInterface |
|
| 24 | + public function matchAndExecute(QueryInterface $query, array $constraints = []): array | QueryResultInterface |
|
| 25 | 25 | { |
| 26 | 26 | if (!empty($constraints)) { |
| 27 | 27 | $query->matching($query->logicalAnd(...$constraints)); |
@@ -556,7 +556,7 @@ |
||
| 556 | 556 | ['calendarize_detail', 'calendarize_index_' . $index->getUid(), 'calendarize_' |
| 557 | 557 | . lcfirst($uniqueRegisterKey) |
| 558 | 558 | . '_' |
| 559 | - . $originalObject->getUid(),] |
|
| 559 | + . $originalObject->getUid(), ] |
|
| 560 | 560 | ); |
| 561 | 561 | |
| 562 | 562 | // Meta tags |