@@ -54,8 +54,8 @@ discard block |
||
| 54 | 54 | */ |
| 55 | 55 | public function getDescription(): string |
| 56 | 56 | { |
| 57 | - return 'This wizard migrates existing front end plugins of the extension Kitodo.Presentation (dlf) to' . |
|
| 58 | - ' make use of the Extbase naming scheme. Therefore it updates the field values' . |
|
| 57 | + return 'This wizard migrates existing front end plugins of the extension Kitodo.Presentation (dlf) to'. |
|
| 58 | + ' make use of the Extbase naming scheme. Therefore it updates the field values'. |
|
| 59 | 59 | ' "pi_flexform" within the tt_content table'; |
| 60 | 60 | } |
| 61 | 61 | |
@@ -170,7 +170,7 @@ discard block |
||
| 170 | 170 | foreach ($fields as $field) { |
| 171 | 171 | // change the index attribute if it doesn't start with 'settings.' yet |
| 172 | 172 | if (strpos($field['index'], 'settings.') === false) { |
| 173 | - $field['index'] = 'settings.' . $field['index']; |
|
| 173 | + $field['index'] = 'settings.'.$field['index']; |
|
| 174 | 174 | } |
| 175 | 175 | } |
| 176 | 176 | |
@@ -172,9 +172,9 @@ discard block |
||
| 172 | 172 | $queryBuilder->createNamedParameter('', \PDO::PARAM_STR) |
| 173 | 173 | ), |
| 174 | 174 | $queryBuilder->expr()->comparison( |
| 175 | - 'CAST(CAST(' . $queryBuilder->quoteIdentifier($this->fieldsToMigrate[$table]) . ' AS DECIMAL) AS CHAR)', |
|
| 175 | + 'CAST(CAST('.$queryBuilder->quoteIdentifier($this->fieldsToMigrate[$table]).' AS DECIMAL) AS CHAR)', |
|
| 176 | 176 | ExpressionBuilder::NEQ, |
| 177 | - 'CAST(' . $queryBuilder->quoteIdentifier($this->fieldsToMigrate[$table]) . ' AS CHAR)' |
|
| 177 | + 'CAST('.$queryBuilder->quoteIdentifier($this->fieldsToMigrate[$table]).' AS CHAR)' |
|
| 178 | 178 | ) |
| 179 | 179 | ) |
| 180 | 180 | ->orderBy('uid') |
@@ -187,7 +187,7 @@ discard block |
||
| 187 | 187 | } |
| 188 | 188 | } catch (DBALException $e) { |
| 189 | 189 | throw new \RuntimeException( |
| 190 | - 'Database query failed. Error was: ' . $e->getPrevious()->getMessage(), |
|
| 190 | + 'Database query failed. Error was: '.$e->getPrevious()->getMessage(), |
|
| 191 | 191 | 1511950673 |
| 192 | 192 | ); |
| 193 | 193 | } |
@@ -246,7 +246,7 @@ discard block |
||
| 246 | 246 | $connectionPool = GeneralUtility::makeInstance(ConnectionPool::class); |
| 247 | 247 | |
| 248 | 248 | $fileUid = null; |
| 249 | - $sourcePath = Environment::getPublicPath() . '/' . $fieldItem; |
|
| 249 | + $sourcePath = Environment::getPublicPath().'/'.$fieldItem; |
|
| 250 | 250 | |
| 251 | 251 | // maybe the file was already moved, so check if the original file still exists |
| 252 | 252 | if (file_exists($sourcePath)) { |
@@ -115,7 +115,7 @@ discard block |
||
| 115 | 115 | $parent->setDoc($doc); |
| 116 | 116 | $success = self::add($parent); |
| 117 | 117 | } else { |
| 118 | - Helper::log('Could not load parent document with UID ' . $document->getDoc()->parentId, LOG_SEVERITY_ERROR); |
|
| 118 | + Helper::log('Could not load parent document with UID '.$document->getDoc()->parentId, LOG_SEVERITY_ERROR); |
|
| 119 | 119 | return false; |
| 120 | 120 | } |
| 121 | 121 | } |
@@ -125,7 +125,7 @@ discard block |
||
| 125 | 125 | self::$processedDocs[] = $document->getUid(); |
| 126 | 126 | // Delete old Solr documents. |
| 127 | 127 | $updateQuery = self::$solr->service->createUpdate(); |
| 128 | - $updateQuery->addDeleteQuery('uid:' . $document->getUid()); |
|
| 128 | + $updateQuery->addDeleteQuery('uid:'.$document->getUid()); |
|
| 129 | 129 | self::$solr->service->update($updateQuery); |
| 130 | 130 | |
| 131 | 131 | // Index every logical unit as separate Solr document. |
@@ -174,14 +174,14 @@ discard block |
||
| 174 | 174 | } catch (\Exception $e) { |
| 175 | 175 | if (!(\TYPO3_REQUESTTYPE & \TYPO3_REQUESTTYPE_CLI)) { |
| 176 | 176 | Helper::addMessage( |
| 177 | - Helper::getLanguageService()->getLL('flash.solrException') . ' ' . htmlspecialchars($e->getMessage()), |
|
| 177 | + Helper::getLanguageService()->getLL('flash.solrException').' '.htmlspecialchars($e->getMessage()), |
|
| 178 | 178 | Helper::getLanguageService()->getLL('flash.error'), |
| 179 | 179 | FlashMessage::ERROR, |
| 180 | 180 | true, |
| 181 | 181 | 'core.template.flashMessages' |
| 182 | 182 | ); |
| 183 | 183 | } |
| 184 | - Helper::log('Apache Solr threw exception: "' . $e->getMessage() . '"', LOG_SEVERITY_ERROR); |
|
| 184 | + Helper::log('Apache Solr threw exception: "'.$e->getMessage().'"', LOG_SEVERITY_ERROR); |
|
| 185 | 185 | return false; |
| 186 | 186 | } |
| 187 | 187 | } else { |
@@ -214,7 +214,7 @@ discard block |
||
| 214 | 214 | // Sanitize input. |
| 215 | 215 | $pid = max(intval($pid), 0); |
| 216 | 216 | if (!$pid) { |
| 217 | - Helper::log('Invalid PID ' . $pid . ' for metadata configuration', LOG_SEVERITY_ERROR); |
|
| 217 | + Helper::log('Invalid PID '.$pid.' for metadata configuration', LOG_SEVERITY_ERROR); |
|
| 218 | 218 | return ''; |
| 219 | 219 | } |
| 220 | 220 | // Load metadata configuration. |
@@ -223,7 +223,7 @@ discard block |
||
| 223 | 223 | $suffix = (in_array($index_name, self::$fields['tokenized']) ? 't' : 'u'); |
| 224 | 224 | $suffix .= (in_array($index_name, self::$fields['stored']) ? 's' : 'u'); |
| 225 | 225 | $suffix .= (in_array($index_name, self::$fields['indexed']) ? 'i' : 'u'); |
| 226 | - $index_name .= '_' . $suffix; |
|
| 226 | + $index_name .= '_'.$suffix; |
|
| 227 | 227 | return $index_name; |
| 228 | 228 | } |
| 229 | 229 | |
@@ -356,11 +356,11 @@ discard block |
||
| 356 | 356 | $solrDoc->setField(self::getIndexFieldName($index_name, $document->getPid()), $data, self::$fields['fieldboost'][$index_name]); |
| 357 | 357 | if (in_array($index_name, self::$fields['sortables'])) { |
| 358 | 358 | // Add sortable fields to index. |
| 359 | - $solrDoc->setField($index_name . '_sorting', $metadata[$index_name . '_sorting'][0]); |
|
| 359 | + $solrDoc->setField($index_name.'_sorting', $metadata[$index_name.'_sorting'][0]); |
|
| 360 | 360 | } |
| 361 | 361 | if (in_array($index_name, self::$fields['facets'])) { |
| 362 | 362 | // Add facets to index. |
| 363 | - $solrDoc->setField($index_name . '_faceting', $data); |
|
| 363 | + $solrDoc->setField($index_name.'_faceting', $data); |
|
| 364 | 364 | } |
| 365 | 365 | if (in_array($index_name, self::$fields['autocomplete'])) { |
| 366 | 366 | $autocomplete = array_merge($autocomplete, $data); |
@@ -385,14 +385,14 @@ discard block |
||
| 385 | 385 | } catch (\Exception $e) { |
| 386 | 386 | if (!(\TYPO3_REQUESTTYPE & \TYPO3_REQUESTTYPE_CLI)) { |
| 387 | 387 | Helper::addMessage( |
| 388 | - Helper::getLanguageService()->getLL('flash.solrException') . '<br />' . htmlspecialchars($e->getMessage()), |
|
| 388 | + Helper::getLanguageService()->getLL('flash.solrException').'<br />'.htmlspecialchars($e->getMessage()), |
|
| 389 | 389 | Helper::getLanguageService()->getLL('flash.error'), |
| 390 | 390 | FlashMessage::ERROR, |
| 391 | 391 | true, |
| 392 | 392 | 'core.template.flashMessages' |
| 393 | 393 | ); |
| 394 | 394 | } |
| 395 | - Helper::log('Apache Solr threw exception: "' . $e->getMessage() . '"', LOG_SEVERITY_ERROR); |
|
| 395 | + Helper::log('Apache Solr threw exception: "'.$e->getMessage().'"', LOG_SEVERITY_ERROR); |
|
| 396 | 396 | return false; |
| 397 | 397 | } |
| 398 | 398 | } |
@@ -458,7 +458,7 @@ discard block |
||
| 458 | 458 | $data = self::removeAppendsFromAuthor($data); |
| 459 | 459 | } |
| 460 | 460 | // Add facets to index. |
| 461 | - $solrDoc->setField($index_name . '_faceting', $data); |
|
| 461 | + $solrDoc->setField($index_name.'_faceting', $data); |
|
| 462 | 462 | } |
| 463 | 463 | } |
| 464 | 464 | } |
@@ -476,14 +476,14 @@ discard block |
||
| 476 | 476 | } catch (\Exception $e) { |
| 477 | 477 | if (!(\TYPO3_REQUESTTYPE & \TYPO3_REQUESTTYPE_CLI)) { |
| 478 | 478 | Helper::addMessage( |
| 479 | - Helper::getLanguageService()->getLL('flash.solrException') . '<br />' . htmlspecialchars($e->getMessage()), |
|
| 479 | + Helper::getLanguageService()->getLL('flash.solrException').'<br />'.htmlspecialchars($e->getMessage()), |
|
| 480 | 480 | Helper::getLanguageService()->getLL('flash.error'), |
| 481 | 481 | FlashMessage::ERROR, |
| 482 | 482 | true, |
| 483 | 483 | 'core.template.flashMessages' |
| 484 | 484 | ); |
| 485 | 485 | } |
| 486 | - Helper::log('Apache Solr threw exception: "' . $e->getMessage() . '"', LOG_SEVERITY_ERROR); |
|
| 486 | + Helper::log('Apache Solr threw exception: "'.$e->getMessage().'"', LOG_SEVERITY_ERROR); |
|
| 487 | 487 | return false; |
| 488 | 488 | } |
| 489 | 489 | } |
@@ -534,7 +534,7 @@ discard block |
||
| 534 | 534 | private static function getSolrDocument($updateQuery, $document, $unit, $fullText = '') { |
| 535 | 535 | $solrDoc = $updateQuery->createDocument(); |
| 536 | 536 | // Create unique identifier from document's UID and unit's XML ID. |
| 537 | - $solrDoc->setField('id', $document->getUid() . $unit['id']); |
|
| 537 | + $solrDoc->setField('id', $document->getUid().$unit['id']); |
|
| 538 | 538 | $solrDoc->setField('uid', $document->getUid()); |
| 539 | 539 | $solrDoc->setField('pid', $document->getPid()); |
| 540 | 540 | $solrDoc->setField('partof', $document->getPartof()); |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | |
| 162 | 162 | // Add uHash parameter to suggest parameter to make a basic protection of this form. |
| 163 | 163 | if ($this->settings['suggest']) { |
| 164 | - $this->view->assign('uHash', GeneralUtility::hmac((string) (new Typo3Version()) . Environment::getExtensionsPath(), 'SearchSuggest')); |
|
| 164 | + $this->view->assign('uHash', GeneralUtility::hmac((string) (new Typo3Version()).Environment::getExtensionsPath(), 'SearchSuggest')); |
|
| 165 | 165 | } |
| 166 | 166 | |
| 167 | 167 | $this->view->assign('viewData', $this->viewData); |
@@ -184,7 +184,7 @@ discard block |
||
| 184 | 184 | // Get facets from plugin configuration. |
| 185 | 185 | $facets = []; |
| 186 | 186 | foreach (GeneralUtility::trimExplode(',', $this->settings['facets'], true) as $facet) { |
| 187 | - $facets[$facet . '_faceting'] = Helper::translate($facet, 'tx_dlf_metadata', $this->settings['storagePid']); |
|
| 187 | + $facets[$facet.'_faceting'] = Helper::translate($facet, 'tx_dlf_metadata', $this->settings['storagePid']); |
|
| 188 | 188 | } |
| 189 | 189 | |
| 190 | 190 | $this->view->assign('facetsMenu', $this->makeFacetsMenuArray($facets)); |
@@ -226,13 +226,13 @@ discard block |
||
| 226 | 226 | $searchParams = $this->searchParams; |
| 227 | 227 | if ( |
| 228 | 228 | (!empty($searchParams['fulltext'])) |
| 229 | - || preg_match('/' . $fields['fulltext'] . ':\((.*)\)/', trim($searchParams['query']), $matches) |
|
| 229 | + || preg_match('/'.$fields['fulltext'].':\((.*)\)/', trim($searchParams['query']), $matches) |
|
| 230 | 230 | ) { |
| 231 | 231 | // If the query already is a fulltext query e.g using the facets |
| 232 | 232 | $searchParams['query'] = empty($matches[1]) ? $searchParams['query'] : $matches[1]; |
| 233 | 233 | // Search in fulltext field if applicable. Query must not be empty! |
| 234 | 234 | if (!empty($this->searchParams['query'])) { |
| 235 | - $search['query'] = $fields['fulltext'] . ':(' . Solr::escapeQuery(trim($searchParams['query'])) . ')'; |
|
| 235 | + $search['query'] = $fields['fulltext'].':('.Solr::escapeQuery(trim($searchParams['query'])).')'; |
|
| 236 | 236 | } |
| 237 | 237 | } else { |
| 238 | 238 | // Retain given search field if valid. |
@@ -256,9 +256,9 @@ discard block |
||
| 256 | 256 | in_array($searchParams['extOperator'][$i], $allowedOperators) |
| 257 | 257 | ) { |
| 258 | 258 | if (!empty($search['query'])) { |
| 259 | - $search['query'] .= ' ' . $searchParams['extOperator'][$i] . ' '; |
|
| 259 | + $search['query'] .= ' '.$searchParams['extOperator'][$i].' '; |
|
| 260 | 260 | } |
| 261 | - $search['query'] .= Indexer::getIndexFieldName($searchParams['extField'][$i], $this->settings['storagePid']) . ':(' . Solr::escapeQuery($searchParams['extQuery'][$i]) . ')'; |
|
| 261 | + $search['query'] .= Indexer::getIndexFieldName($searchParams['extField'][$i], $this->settings['storagePid']).':('.Solr::escapeQuery($searchParams['extQuery'][$i]).')'; |
|
| 262 | 262 | } |
| 263 | 263 | } |
| 264 | 264 | } |
@@ -383,7 +383,7 @@ discard block |
||
| 383 | 383 | $entryArray['doNotLinkIt'] = 0; |
| 384 | 384 | // Check if facet is already selected. |
| 385 | 385 | $queryColumn = array_column($search['params']['filterquery'], 'query'); |
| 386 | - $index = array_search($field . ':("' . Solr::escapeQuery($value) . '")', $queryColumn); |
|
| 386 | + $index = array_search($field.':("'.Solr::escapeQuery($value).'")', $queryColumn); |
|
| 387 | 387 | if ($index !== false) { |
| 388 | 388 | // Facet is selected, thus remove it from filter. |
| 389 | 389 | unset($queryColumn[$index]); |
@@ -397,7 +397,7 @@ discard block |
||
| 397 | 397 | } |
| 398 | 398 | } else { |
| 399 | 399 | // Facet is not selected, thus add it to filter. |
| 400 | - $queryColumn[] = $field . ':("' . Solr::escapeQuery($value) . '")'; |
|
| 400 | + $queryColumn[] = $field.':("'.Solr::escapeQuery($value).'")'; |
|
| 401 | 401 | $entryArray['ITEM_STATE'] = 'NO'; |
| 402 | 402 | } |
| 403 | 403 | $entryArray['queryColumn'] = $queryColumn; |
@@ -15,10 +15,10 @@ |
||
| 15 | 15 | preg_match("@.*/(?:acceptance|functional-[a-z0-9]+)@", $_SERVER['REQUEST_URI'], $matches); |
| 16 | 16 | |
| 17 | 17 | if (!empty($matches)) { |
| 18 | - $root = realpath($_SERVER['DOCUMENT_ROOT'] . $matches[0]); |
|
| 18 | + $root = realpath($_SERVER['DOCUMENT_ROOT'].$matches[0]); |
|
| 19 | 19 | if ($root !== false) { |
| 20 | - putenv('TYPO3_PATH_ROOT=' . $root); |
|
| 21 | - putenv('TYPO3_PATH_APP=' . $root); |
|
| 20 | + putenv('TYPO3_PATH_ROOT='.$root); |
|
| 21 | + putenv('TYPO3_PATH_APP='.$root); |
|
| 22 | 22 | } |
| 23 | 23 | } |
| 24 | 24 | |
@@ -77,7 +77,7 @@ |
||
| 77 | 77 | ]); |
| 78 | 78 | |
| 79 | 79 | $this->assertEquals(200, $response->getStatusCode()); |
| 80 | - $this->assertEquals('This is some plain text test file.' . "\n", (string) $response->getBody()); |
|
| 80 | + $this->assertEquals('This is some plain text test file.'."\n", (string) $response->getBody()); |
|
| 81 | 81 | } |
| 82 | 82 | |
| 83 | 83 | /** |
@@ -21,9 +21,9 @@ |
||
| 21 | 21 | |
| 22 | 22 | $this->documentRepository = $this->initializeRepository(DocumentRepository::class, 20000); |
| 23 | 23 | |
| 24 | - $this->importDataSet(__DIR__ . '/../../Fixtures/Common/documents_1.xml'); |
|
| 25 | - $this->importDataSet(__DIR__ . '/../../Fixtures/Common/pages.xml'); |
|
| 26 | - $this->importDataSet(__DIR__ . '/../../Fixtures/Common/libraries.xml'); |
|
| 24 | + $this->importDataSet(__DIR__.'/../../Fixtures/Common/documents_1.xml'); |
|
| 25 | + $this->importDataSet(__DIR__.'/../../Fixtures/Common/pages.xml'); |
|
| 26 | + $this->importDataSet(__DIR__.'/../../Fixtures/Common/libraries.xml'); |
|
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | /** |
@@ -183,7 +183,7 @@ discard block |
||
| 183 | 183 | |
| 184 | 184 | // There may be a single non-signifying space after the doc-comment asterisk, |
| 185 | 185 | // which is not included. |
| 186 | - $text .= preg_replace('#\\s*/?[*/]*\\s?(.*)$#', '$1', $line) . "\n"; |
|
| 186 | + $text .= preg_replace('#\\s*/?[*/]*\\s?(.*)$#', '$1', $line)."\n"; |
|
| 187 | 187 | } |
| 188 | 188 | $text = trim($text); |
| 189 | 189 | |
@@ -204,7 +204,7 @@ discard block |
||
| 204 | 204 | RST); |
| 205 | 205 | |
| 206 | 206 | // Sort tables alphabetically |
| 207 | - usort($tables, function ($lhs, $rhs) { |
|
| 207 | + usort($tables, function($lhs, $rhs) { |
|
| 208 | 208 | return $lhs->name <=> $rhs->name; |
| 209 | 209 | }); |
| 210 | 210 | |
@@ -214,13 +214,13 @@ discard block |
||
| 214 | 214 | // Set header |
| 215 | 215 | $header = $tableInfo->name; |
| 216 | 216 | if (!empty($tableInfo->feComment)) { |
| 217 | - $header .= ': ' . $tableInfo->feComment; |
|
| 217 | + $header .= ': '.$tableInfo->feComment; |
|
| 218 | 218 | } |
| 219 | 219 | $section->setHeader($header); |
| 220 | 220 | |
| 221 | 221 | // Set introductory text of subsection |
| 222 | 222 | if ($tableInfo->modelClass) { |
| 223 | - $section->addText('Extbase domain model: ``' . $tableInfo->modelClass . '``'); |
|
| 223 | + $section->addText('Extbase domain model: ``'.$tableInfo->modelClass.'``'); |
|
| 224 | 224 | } |
| 225 | 225 | $section->addText($tableInfo->classComment); |
| 226 | 226 | $section->addText($tableInfo->sqlComment); |
@@ -231,7 +231,7 @@ discard block |
||
| 231 | 231 | 'description' => 'Description', |
| 232 | 232 | ]]; |
| 233 | 233 | |
| 234 | - $rows = array_map(function ($column) use ($page) { |
|
| 234 | + $rows = array_map(function($column) use ($page) { |
|
| 235 | 235 | return [ |
| 236 | 236 | 'field' => ( |
| 237 | 237 | $page->format($column->name, ['bold' => $column->isPrimary]) |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | foreach ($this->requestData['selected'] as $docValue) { |
| 110 | 110 | if ($docValue['id']) { |
| 111 | 111 | $docData = $this->getDocumentData($docValue['id'], $docValue); |
| 112 | - $pdfUrl .= $docData['urlParams'] . $this->settings['pdfparamseparator']; |
|
| 112 | + $pdfUrl .= $docData['urlParams'].$this->settings['pdfparamseparator']; |
|
| 113 | 113 | $this->redirectToUri($pdfUrl); |
| 114 | 114 | } |
| 115 | 115 | } |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | if ($allMails->count() > 0) { |
| 173 | 173 | $mailSelect[0] = htmlspecialchars(LocalizationUtility::translate('basket.chooseMail', 'dlf')); |
| 174 | 174 | foreach ($allMails as $mail) { |
| 175 | - $mailSelect[$mail->getUid()] = htmlspecialchars($mail->getName()) . ' (' . htmlspecialchars($mail->getMail()) . ')'; |
|
| 175 | + $mailSelect[$mail->getUid()] = htmlspecialchars($mail->getName()).' ('.htmlspecialchars($mail->getMail()).')'; |
|
| 176 | 176 | } |
| 177 | 177 | $this->view->assign('mailSelect', $mailSelect); |
| 178 | 178 | } |
@@ -256,12 +256,12 @@ discard block |
||
| 256 | 256 | |
| 257 | 257 | $entryArray['BASKETDATA'] = $docData; |
| 258 | 258 | |
| 259 | - $entryKey = $id . '_' . $startpage; |
|
| 259 | + $entryKey = $id.'_'.$startpage; |
|
| 260 | 260 | if (!empty($startX)) { |
| 261 | - $entryKey .= '_' . $startX; |
|
| 261 | + $entryKey .= '_'.$startX; |
|
| 262 | 262 | } |
| 263 | 263 | if (!empty($endX)) { |
| 264 | - $entryKey .= '_' . $endX; |
|
| 264 | + $entryKey .= '_'.$endX; |
|
| 265 | 265 | } |
| 266 | 266 | |
| 267 | 267 | $entryArray['id'] = $id; |
@@ -312,7 +312,7 @@ discard block |
||
| 312 | 312 | $urlParams = str_replace("##endy##", $data['endY'] === "" ? "" : (int) $data['endY'], $urlParams); |
| 313 | 313 | $urlParams = str_replace("##rotation##", $data['rotation'] === "" ? "" : (int) $data['rotation'], $urlParams); |
| 314 | 314 | |
| 315 | - $downloadUrl = $this->settings['pdfgenerate'] . $urlParams; |
|
| 315 | + $downloadUrl = $this->settings['pdfgenerate'].$urlParams; |
|
| 316 | 316 | |
| 317 | 317 | $title = $this->document->getTitle(); |
| 318 | 318 | if (empty($title)) { |
@@ -323,15 +323,15 @@ discard block |
||
| 323 | 323 | $info = ''; |
| 324 | 324 | if ($data['startX'] != '' && $data['endX'] != '') { |
| 325 | 325 | // cutout |
| 326 | - $info .= htmlspecialchars(LocalizationUtility::translate('basket.cutout', 'dlf')) . ' '; |
|
| 326 | + $info .= htmlspecialchars(LocalizationUtility::translate('basket.cutout', 'dlf')).' '; |
|
| 327 | 327 | } |
| 328 | 328 | if ($data['startpage'] == $data['endpage']) { |
| 329 | 329 | // One page |
| 330 | - $info .= htmlspecialchars(LocalizationUtility::translate('page', 'dlf')) . ' ' . $data['startpage']; |
|
| 330 | + $info .= htmlspecialchars(LocalizationUtility::translate('page', 'dlf')).' '.$data['startpage']; |
|
| 331 | 331 | } else { |
| 332 | - $info .= htmlspecialchars(LocalizationUtility::translate('page', 'dlf')) . ' ' . $data['startpage'] . '-' . $data['endpage']; |
|
| 332 | + $info .= htmlspecialchars(LocalizationUtility::translate('page', 'dlf')).' '.$data['startpage'].'-'.$data['endpage']; |
|
| 333 | 333 | } |
| 334 | - $downloadLink = '<a href="' . $downloadUrl . '" target="_blank">' . htmlspecialchars($title) . '</a> (' . $info . ')'; |
|
| 334 | + $downloadLink = '<a href="'.$downloadUrl.'" target="_blank">'.htmlspecialchars($title).'</a> ('.$info.')'; |
|
| 335 | 335 | if ($data['startpage'] == $data['endpage']) { |
| 336 | 336 | $pageNums = 1; |
| 337 | 337 | } else { |
@@ -407,12 +407,12 @@ discard block |
||
| 407 | 407 | if ($_piVars['addToBasket'] == 'list') { |
| 408 | 408 | $documentItem['endpage'] = $this->document->getDoc()->numPages; |
| 409 | 409 | } |
| 410 | - $arrayKey = $documentItem['id'] . '_' . $page; |
|
| 410 | + $arrayKey = $documentItem['id'].'_'.$page; |
|
| 411 | 411 | if (!empty($documentItem['startX'])) { |
| 412 | - $arrayKey .= '_' . $documentItem['startX']; |
|
| 412 | + $arrayKey .= '_'.$documentItem['startX']; |
|
| 413 | 413 | } |
| 414 | 414 | if (!empty($documentItem['endX'])) { |
| 415 | - $arrayKey .= '_' . $documentItem['endX']; |
|
| 415 | + $arrayKey .= '_'.$documentItem['endX']; |
|
| 416 | 416 | } |
| 417 | 417 | // do not add more than one identical object |
| 418 | 418 | if (!in_array($arrayKey, $items)) { |
@@ -431,14 +431,14 @@ discard block |
||
| 431 | 431 | // remove parameter endpage |
| 432 | 432 | $pdfParams = str_replace(",##endpage##", '', $pdfParams); |
| 433 | 433 | } |
| 434 | - $pdfGenerateUrl = $this->settings['pdfgenerate'] . $pdfParams; |
|
| 434 | + $pdfGenerateUrl = $this->settings['pdfgenerate'].$pdfParams; |
|
| 435 | 435 | if ($this->settings['pregeneration']) { |
| 436 | 436 | // send ajax request to webapp |
| 437 | 437 | $output .= ' |
| 438 | 438 | <script> |
| 439 | 439 | $(document).ready(function(){ |
| 440 | 440 | $.ajax({ |
| 441 | - url: "' . $pdfGenerateUrl . '", |
|
| 441 | + url: "' . $pdfGenerateUrl.'", |
|
| 442 | 442 | }).done(function() { |
| 443 | 443 | }); |
| 444 | 444 | }); |
@@ -476,12 +476,12 @@ discard block |
||
| 476 | 476 | } |
| 477 | 477 | foreach ($_piVars['selected'] as $value) { |
| 478 | 478 | if (isset($value['id'])) { |
| 479 | - $arrayKey = $value['id'] . '_' . $value['startpage']; |
|
| 479 | + $arrayKey = $value['id'].'_'.$value['startpage']; |
|
| 480 | 480 | if (!empty($value['startX'])) { |
| 481 | - $arrayKey .= '_' . $value['startX']; |
|
| 481 | + $arrayKey .= '_'.$value['startX']; |
|
| 482 | 482 | } |
| 483 | 483 | if (!empty($value['endX'])) { |
| 484 | - $arrayKey .= '_' . $value['endX']; |
|
| 484 | + $arrayKey .= '_'.$value['endX']; |
|
| 485 | 485 | } |
| 486 | 486 | if (isset($items[$arrayKey])) { |
| 487 | 487 | unset($items[$arrayKey]); |
@@ -514,7 +514,7 @@ discard block |
||
| 514 | 514 | |
| 515 | 515 | $mailObject = $this->mailRepository->findByUid(intval($mailId))->getFirst(); |
| 516 | 516 | |
| 517 | - $mailText = htmlspecialchars(LocalizationUtility::translate('basket.mailBody', 'dlf')) . "\n"; |
|
| 517 | + $mailText = htmlspecialchars(LocalizationUtility::translate('basket.mailBody', 'dlf'))."\n"; |
|
| 518 | 518 | $numberOfPages = 0; |
| 519 | 519 | $pdfUrl = $this->settings['pdfdownload']; |
| 520 | 520 | // prepare links |
@@ -522,7 +522,7 @@ discard block |
||
| 522 | 522 | if ($docValue['id']) { |
| 523 | 523 | $explodeId = explode("_", $docValue['id']); |
| 524 | 524 | $docData = $this->getDocumentData($explodeId[0], $docValue); |
| 525 | - $pdfUrl .= $docData['urlParams'] . $this->settings['pdfparamseparator']; |
|
| 525 | + $pdfUrl .= $docData['urlParams'].$this->settings['pdfparamseparator']; |
|
| 526 | 526 | $pages = (abs(intval($docValue['startpage']) - intval($docValue['endpage']))); |
| 527 | 527 | if ($pages === 0) { |
| 528 | 528 | $numberOfPages = $numberOfPages + 1; |
@@ -533,7 +533,7 @@ discard block |
||
| 533 | 533 | } |
| 534 | 534 | // Remove leading/tailing pdfparamseperator |
| 535 | 535 | $pdfUrl = trim($pdfUrl, $this->settings['pdfparamseparator']); |
| 536 | - $mailBody = $mailText . $pdfUrl; |
|
| 536 | + $mailBody = $mailText.$pdfUrl; |
|
| 537 | 537 | // Get hook objects. |
| 538 | 538 | $hookObjects = Helper::getHookObjects('Classes/Controller/BasketController.php'); |
| 539 | 539 | // Hook for getting a customized mail body. |
@@ -560,7 +560,7 @@ discard block |
||
| 560 | 560 | $newActionLog = GeneralUtility::makeInstance(ActionLog::class); |
| 561 | 561 | $newActionLog->setFileName($pdfUrl); |
| 562 | 562 | $newActionLog->setCountPages($numberOfPages); |
| 563 | - $newActionLog->setLabel('Mail: ' . $mailObject->getMail()); |
|
| 563 | + $newActionLog->setLabel('Mail: '.$mailObject->getMail()); |
|
| 564 | 564 | |
| 565 | 565 | if ($GLOBALS["TSFE"]->loginUser) { |
| 566 | 566 | // internal user |
@@ -592,7 +592,7 @@ discard block |
||
| 592 | 592 | foreach ($this->requestData['selected'] as $docId => $docValue) { |
| 593 | 593 | if ($docValue['id']) { |
| 594 | 594 | $docData = $this->getDocumentData($docValue['id'], $docValue); |
| 595 | - $pdfUrl .= $docData['urlParams'] . $this->settings['pdfparamseparator']; |
|
| 595 | + $pdfUrl .= $docData['urlParams'].$this->settings['pdfparamseparator']; |
|
| 596 | 596 | $numberOfPages += $docData['pageNums']; |
| 597 | 597 | } |
| 598 | 598 | } |
@@ -610,7 +610,7 @@ discard block |
||
| 610 | 610 | if ($docValue['id']) { |
| 611 | 611 | $explodeId = explode("_", $docId); |
| 612 | 612 | $docData = $this->getDocumentData($explodeId[0], $docValue); |
| 613 | - $pdfUrl .= $docData['urlParams'] . $this->settings['pdfparamseparator']; |
|
| 613 | + $pdfUrl .= $docData['urlParams'].$this->settings['pdfparamseparator']; |
|
| 614 | 614 | $numberOfPages += $docData['pageNums']; |
| 615 | 615 | } |
| 616 | 616 | } |
@@ -627,12 +627,12 @@ discard block |
||
| 627 | 627 | // internal user |
| 628 | 628 | $actionLog->setUserId($GLOBALS["TSFE"]->fe_user->user['uid']); |
| 629 | 629 | $actionLog->setName($GLOBALS["TSFE"]->fe_user->user['username']); |
| 630 | - $actionLog->setLabel('Print: ' . $printer->getLabel()); |
|
| 630 | + $actionLog->setLabel('Print: '.$printer->getLabel()); |
|
| 631 | 631 | } else { |
| 632 | 632 | // external user |
| 633 | 633 | $actionLog->setUserId(0); |
| 634 | 634 | $actionLog->setName('n/a'); |
| 635 | - $actionLog->setLabel('Print: ' . $printer->getLabel()); |
|
| 635 | + $actionLog->setLabel('Print: '.$printer->getLabel()); |
|
| 636 | 636 | } |
| 637 | 637 | // add action to protocol |
| 638 | 638 | $this->actionLogRepository->add($actionLog); |