@@ -146,11 +146,11 @@ discard block |
||
146 | 146 | $fulltext['mimetype'] = $this->document->getDoc()->getFileMimeType($this->document->getDoc()->physicalStructureInfo[$this->document->getDoc()->physicalStructure[$page]]['files'][$fileGrpFulltext]); |
147 | 147 | break; |
148 | 148 | } else { |
149 | - $this->logger->notice('No full-text file found for page "' . $page . '" in fileGrp "' . $fileGrpFulltext . '"'); |
|
149 | + $this->logger->notice('No full-text file found for page "'.$page.'" in fileGrp "'.$fileGrpFulltext.'"'); |
|
150 | 150 | } |
151 | 151 | } |
152 | 152 | if (empty($fulltext)) { |
153 | - $this->logger->notice('No full-text file found for page "' . $page . '" in fileGrps "' . $this->extConf['fileGrpFulltext'] . '"'); |
|
153 | + $this->logger->notice('No full-text file found for page "'.$page.'" in fileGrps "'.$this->extConf['fileGrpFulltext'].'"'); |
|
154 | 154 | } |
155 | 155 | return $fulltext; |
156 | 156 | } |
@@ -168,13 +168,13 @@ discard block |
||
168 | 168 | $viewerConfiguration = '$(document).ready(function() { |
169 | 169 | if (dlfUtils.exists(dlfViewer)) { |
170 | 170 | tx_dlf_viewer = new dlfViewer({ |
171 | - controls: ["' . implode('", "', $this->controls) . '"], |
|
172 | - div: "' . $this->settings['elementId'] . '", |
|
173 | - progressElementId: "' . $this->settings['progressElementId'] . '", |
|
174 | - images: ' . json_encode($this->images) . ', |
|
175 | - fulltexts: ' . json_encode($this->fulltexts) . ', |
|
176 | - annotationContainers: ' . json_encode($this->annotationContainers) . ', |
|
177 | - useInternalProxy: ' . ($this->settings['useInternalProxy'] ? 1 : 0) . ' |
|
171 | + controls: ["' . implode('", "', $this->controls).'"], |
|
172 | + div: "' . $this->settings['elementId'].'", |
|
173 | + progressElementId: "' . $this->settings['progressElementId'].'", |
|
174 | + images: ' . json_encode($this->images).', |
|
175 | + fulltexts: ' . json_encode($this->fulltexts).', |
|
176 | + annotationContainers: ' . json_encode($this->annotationContainers).', |
|
177 | + useInternalProxy: ' . ($this->settings['useInternalProxy'] ? 1 : 0).' |
|
178 | 178 | }); |
179 | 179 | } |
180 | 180 | });'; |
@@ -275,11 +275,11 @@ discard block |
||
275 | 275 | } |
276 | 276 | break; |
277 | 277 | } else { |
278 | - $this->logger->notice('No image file found for page "' . $page . '" in fileGrp "' . $fileGrpImages . '"'); |
|
278 | + $this->logger->notice('No image file found for page "'.$page.'" in fileGrp "'.$fileGrpImages.'"'); |
|
279 | 279 | } |
280 | 280 | } |
281 | 281 | if (empty($image)) { |
282 | - $this->logger->warning('No image file found for page "' . $page . '" in fileGrps "' . $this->extConf['fileGrpImages'] . '"'); |
|
282 | + $this->logger->warning('No image file found for page "'.$page.'" in fileGrps "'.$this->extConf['fileGrpImages'].'"'); |
|
283 | 283 | } |
284 | 284 | return $image; |
285 | 285 | } |
@@ -48,6 +48,6 @@ |
||
48 | 48 | $metadata['video_duration'] = [$videoDuration]; |
49 | 49 | } |
50 | 50 | |
51 | - $metadata['duration'] = $metadata['video_duration'] ?: $metadata['audio_duration'] ?: []; |
|
51 | + $metadata['duration'] = $metadata['video_duration'] ? : $metadata['audio_duration'] ? : []; |
|
52 | 52 | } |
53 | 53 | } |
@@ -217,7 +217,7 @@ discard block |
||
217 | 217 | $fileMimeType = $this->getFileMimeType($id); |
218 | 218 | $fileLocation = $this->getFileLocation($id); |
219 | 219 | if ($fileMimeType === 'application/vnd.kitodo.iiif') { |
220 | - $fileLocation = (strrpos($fileLocation, 'info.json') === strlen($fileLocation) - 9) ? $fileLocation : (strrpos($fileLocation, '/') === strlen($fileLocation) ? $fileLocation . 'info.json' : $fileLocation . '/info.json'); |
|
220 | + $fileLocation = (strrpos($fileLocation, 'info.json') === strlen($fileLocation) - 9) ? $fileLocation : (strrpos($fileLocation, '/') === strlen($fileLocation) ? $fileLocation.'info.json' : $fileLocation.'/info.json'); |
|
221 | 221 | $conf = GeneralUtility::makeInstance(ExtensionConfiguration::class)->get(self::$extKey); |
222 | 222 | IiifHelper::setUrlReader(IiifUrlReader::getInstance()); |
223 | 223 | IiifHelper::setMaxThumbnailHeight($conf['iiifThumbnailHeight']); |
@@ -227,9 +227,9 @@ discard block |
||
227 | 227 | return $service->getImageUrl(); |
228 | 228 | } |
229 | 229 | } elseif ($fileMimeType === 'application/vnd.netfpx') { |
230 | - $baseURL = $fileLocation . (strpos($fileLocation, '?') === false ? '?' : ''); |
|
230 | + $baseURL = $fileLocation.(strpos($fileLocation, '?') === false ? '?' : ''); |
|
231 | 231 | // TODO CVT is an optional IIP server capability; in theory, capabilities should be determined in the object request with '&obj=IIP-server' |
232 | - return $baseURL . '&CVT=jpeg'; |
|
232 | + return $baseURL.'&CVT=jpeg'; |
|
233 | 233 | } |
234 | 234 | return $fileLocation; |
235 | 235 | } |
@@ -240,14 +240,14 @@ discard block |
||
240 | 240 | */ |
241 | 241 | public function getFileLocation($id) |
242 | 242 | { |
243 | - $location = $this->mets->xpath('./mets:fileSec/mets:fileGrp/mets:file[@ID="' . $id . '"]/mets:FLocat[@LOCTYPE="URL"]'); |
|
243 | + $location = $this->mets->xpath('./mets:fileSec/mets:fileGrp/mets:file[@ID="'.$id.'"]/mets:FLocat[@LOCTYPE="URL"]'); |
|
244 | 244 | if ( |
245 | 245 | !empty($id) |
246 | 246 | && !empty($location) |
247 | 247 | ) { |
248 | 248 | return (string) $location[0]->attributes('http://www.w3.org/1999/xlink')->href; |
249 | 249 | } else { |
250 | - $this->logger->warning('There is no file node with @ID "' . $id . '"'); |
|
250 | + $this->logger->warning('There is no file node with @ID "'.$id.'"'); |
|
251 | 251 | return ''; |
252 | 252 | } |
253 | 253 | } |
@@ -258,14 +258,14 @@ discard block |
||
258 | 258 | */ |
259 | 259 | public function getFileMimeType($id) |
260 | 260 | { |
261 | - $mimetype = $this->mets->xpath('./mets:fileSec/mets:fileGrp/mets:file[@ID="' . $id . '"]/@MIMETYPE'); |
|
261 | + $mimetype = $this->mets->xpath('./mets:fileSec/mets:fileGrp/mets:file[@ID="'.$id.'"]/@MIMETYPE'); |
|
262 | 262 | if ( |
263 | 263 | !empty($id) |
264 | 264 | && !empty($mimetype) |
265 | 265 | ) { |
266 | 266 | return (string) $mimetype[0]; |
267 | 267 | } else { |
268 | - $this->logger->warning('There is no file node with @ID "' . $id . '" or no MIME type specified'); |
|
268 | + $this->logger->warning('There is no file node with @ID "'.$id.'" or no MIME type specified'); |
|
269 | 269 | return ''; |
270 | 270 | } |
271 | 271 | } |
@@ -286,7 +286,7 @@ discard block |
||
286 | 286 | return $this->logicalUnits[$id]; |
287 | 287 | } elseif (!empty($id)) { |
288 | 288 | // Get specified logical unit. |
289 | - $divs = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="' . $id . '"]'); |
|
289 | + $divs = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="'.$id.'"]'); |
|
290 | 290 | } else { |
291 | 291 | // Get all logical units at top level. |
292 | 292 | $divs = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]/mets:div'); |
@@ -427,7 +427,7 @@ discard block |
||
427 | 427 | // Retain current PID. |
428 | 428 | $cPid = ($this->cPid ? $this->cPid : $this->pid); |
429 | 429 | } elseif (!$cPid) { |
430 | - $this->logger->warning('Invalid PID ' . $cPid . ' for metadata definitions'); |
|
430 | + $this->logger->warning('Invalid PID '.$cPid.' for metadata definitions'); |
|
431 | 431 | return []; |
432 | 432 | } |
433 | 433 | // Get metadata from parsed metadata array if available. |
@@ -478,7 +478,7 @@ discard block |
||
478 | 478 | if (!empty($this->logicalUnits[$id])) { |
479 | 479 | $metadata['type'] = [$this->logicalUnits[$id]['type']]; |
480 | 480 | } else { |
481 | - $struct = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="' . $id . '"]/@TYPE'); |
|
481 | + $struct = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="'.$id.'"]/@TYPE'); |
|
482 | 482 | if (!empty($struct)) { |
483 | 483 | $metadata['type'] = [(string) $struct[0]]; |
484 | 484 | } |
@@ -503,11 +503,11 @@ discard block |
||
503 | 503 | ) { |
504 | 504 | $obj->extractMetadata($this->mdSec[$dmdId]['xml'], $metadata); |
505 | 505 | } else { |
506 | - $this->logger->warning('Invalid class/method "' . $class . '->extractMetadata()" for metadata format "' . $this->mdSec[$dmdId]['type'] . '"'); |
|
506 | + $this->logger->warning('Invalid class/method "'.$class.'->extractMetadata()" for metadata format "'.$this->mdSec[$dmdId]['type'].'"'); |
|
507 | 507 | } |
508 | 508 | } |
509 | 509 | } else { |
510 | - $this->logger->notice('Unsupported metadata format "' . $this->mdSec[$dmdId]['type'] . '" in ' . $mdSectionType . ' with @ID "' . $dmdId . '"'); |
|
510 | + $this->logger->notice('Unsupported metadata format "'.$this->mdSec[$dmdId]['type'].'" in '.$mdSectionType.' with @ID "'.$dmdId.'"'); |
|
511 | 511 | // Continue searching for supported metadata with next @DMDID. |
512 | 512 | continue; |
513 | 513 | } |
@@ -623,13 +623,13 @@ discard block |
||
623 | 623 | $values instanceof \DOMNodeList |
624 | 624 | && $values->length > 0 |
625 | 625 | ) { |
626 | - $metadata[$resArray['index_name'] . '_sorting'][0] = trim((string) $values->item(0)->nodeValue); |
|
626 | + $metadata[$resArray['index_name'].'_sorting'][0] = trim((string) $values->item(0)->nodeValue); |
|
627 | 627 | } elseif (!($values instanceof \DOMNodeList)) { |
628 | - $metadata[$resArray['index_name'] . '_sorting'][0] = trim((string) $values); |
|
628 | + $metadata[$resArray['index_name'].'_sorting'][0] = trim((string) $values); |
|
629 | 629 | } |
630 | 630 | } |
631 | - if (empty($metadata[$resArray['index_name'] . '_sorting'][0])) { |
|
632 | - $metadata[$resArray['index_name'] . '_sorting'][0] = $metadata[$resArray['index_name']][0]; |
|
631 | + if (empty($metadata[$resArray['index_name'].'_sorting'][0])) { |
|
632 | + $metadata[$resArray['index_name'].'_sorting'][0] = $metadata[$resArray['index_name']][0]; |
|
633 | 633 | } |
634 | 634 | } |
635 | 635 | } |
@@ -645,7 +645,7 @@ discard block |
||
645 | 645 | if (isset($this->fileInfos[$id]) || isset($hasMetadataSection['dmdSec'])) { |
646 | 646 | return $metadata; |
647 | 647 | } else { |
648 | - $this->logger->warning('No supported descriptive metadata found for logical structure with @ID "' . $id . '"'); |
|
648 | + $this->logger->warning('No supported descriptive metadata found for logical structure with @ID "'.$id.'"'); |
|
649 | 649 | return []; |
650 | 650 | } |
651 | 651 | } |
@@ -670,7 +670,7 @@ discard block |
||
670 | 670 | $dmdIds = $this->logicalUnits[$id]['dmdId'] ?? ''; |
671 | 671 | $admIds = $this->logicalUnits[$id]['admId'] ?? ''; |
672 | 672 | } else { |
673 | - $mdSec = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="' . $id . '"]')[0]; |
|
673 | + $mdSec = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="'.$id.'"]')[0]; |
|
674 | 674 | if ($mdSec) { |
675 | 675 | $dmdIds = (string) $mdSec->attributes()->DMDID; |
676 | 676 | $admIds = (string) $mdSec->attributes()->ADMID; |
@@ -698,7 +698,7 @@ discard block |
||
698 | 698 | } |
699 | 699 | } |
700 | 700 | |
701 | - return array_filter($allMdIds, function ($element) { |
|
701 | + return array_filter($allMdIds, function($element) { |
|
702 | 702 | return !empty($element); |
703 | 703 | }); |
704 | 704 | } |
@@ -725,7 +725,7 @@ discard block |
||
725 | 725 | */ |
726 | 726 | public function getStructureDepth($logId) |
727 | 727 | { |
728 | - $ancestors = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="' . $logId . '"]/ancestor::*'); |
|
728 | + $ancestors = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="'.$logId.'"]/ancestor::*'); |
|
729 | 729 | if (!empty($ancestors)) { |
730 | 730 | return count($ancestors); |
731 | 731 | } else { |
@@ -749,9 +749,9 @@ discard block |
||
749 | 749 | $this->registerNamespaces($this->mets); |
750 | 750 | } else { |
751 | 751 | if (!empty($location)) { |
752 | - $this->logger->error('No METS part found in document with location "' . $location . '".'); |
|
752 | + $this->logger->error('No METS part found in document with location "'.$location.'".'); |
|
753 | 753 | } else if (!empty($this->recordId)) { |
754 | - $this->logger->error('No METS part found in document with recordId "' . $this->recordId . '".'); |
|
754 | + $this->logger->error('No METS part found in document with recordId "'.$this->recordId.'".'); |
|
755 | 755 | } else { |
756 | 756 | $this->logger->error('No METS part found in current document.'); |
757 | 757 | } |
@@ -773,7 +773,7 @@ discard block |
||
773 | 773 | return true; |
774 | 774 | } |
775 | 775 | } |
776 | - $this->logger->error('Could not load XML file from "' . $location . '"'); |
|
776 | + $this->logger->error('Could not load XML file from "'.$location.'"'); |
|
777 | 777 | return false; |
778 | 778 | } |
779 | 779 | |
@@ -888,12 +888,12 @@ discard block |
||
888 | 888 | if ($type = $element->xpath('./mets:mdWrap[not(@MDTYPE="OTHER")]/@MDTYPE')) { |
889 | 889 | if (!empty($this->formats[(string) $type[0]])) { |
890 | 890 | $type = (string) $type[0]; |
891 | - $xml = $element->xpath('./mets:mdWrap[@MDTYPE="' . $type . '"]/mets:xmlData/' . strtolower($type) . ':' . $this->formats[$type]['rootElement']); |
|
891 | + $xml = $element->xpath('./mets:mdWrap[@MDTYPE="'.$type.'"]/mets:xmlData/'.strtolower($type).':'.$this->formats[$type]['rootElement']); |
|
892 | 892 | } |
893 | 893 | } elseif ($type = $element->xpath('./mets:mdWrap[@MDTYPE="OTHER"]/@OTHERMDTYPE')) { |
894 | 894 | if (!empty($this->formats[(string) $type[0]])) { |
895 | 895 | $type = (string) $type[0]; |
896 | - $xml = $element->xpath('./mets:mdWrap[@MDTYPE="OTHER"][@OTHERMDTYPE="' . $type . '"]/mets:xmlData/' . strtolower($type) . ':' . $this->formats[$type]['rootElement']); |
|
896 | + $xml = $element->xpath('./mets:mdWrap[@MDTYPE="OTHER"][@OTHERMDTYPE="'.$type.'"]/mets:xmlData/'.strtolower($type).':'.$this->formats[$type]['rootElement']); |
|
897 | 897 | } |
898 | 898 | } |
899 | 899 | |
@@ -1100,7 +1100,7 @@ discard block |
||
1100 | 1100 | // Retain current PID. |
1101 | 1101 | $cPid = ($this->cPid ? $this->cPid : $this->pid); |
1102 | 1102 | if (!$cPid) { |
1103 | - $this->logger->error('Invalid PID ' . $cPid . ' for structure definitions'); |
|
1103 | + $this->logger->error('Invalid PID '.$cPid.' for structure definitions'); |
|
1104 | 1104 | $this->thumbnailLoaded = true; |
1105 | 1105 | return $this->thumbnail; |
1106 | 1106 | } |
@@ -1137,7 +1137,7 @@ discard block |
||
1137 | 1137 | if (!empty($resArray['thumbnail'])) { |
1138 | 1138 | $strctType = Helper::getIndexNameFromUid($resArray['thumbnail'], 'tx_dlf_structures', $cPid); |
1139 | 1139 | // Check if this document has a structure element of the desired type. |
1140 | - $strctIds = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@TYPE="' . $strctType . '"]/@ID'); |
|
1140 | + $strctIds = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@TYPE="'.$strctType.'"]/@ID'); |
|
1141 | 1141 | if (!empty($strctIds)) { |
1142 | 1142 | $strctId = (string) $strctIds[0]; |
1143 | 1143 | } |
@@ -1160,7 +1160,7 @@ discard block |
||
1160 | 1160 | } |
1161 | 1161 | } |
1162 | 1162 | } else { |
1163 | - $this->logger->error('No structure of type "' . $metadata['type'][0] . '" found in database'); |
|
1163 | + $this->logger->error('No structure of type "'.$metadata['type'][0].'" found in database'); |
|
1164 | 1164 | } |
1165 | 1165 | $this->thumbnailLoaded = true; |
1166 | 1166 | } |
@@ -1207,7 +1207,7 @@ discard block |
||
1207 | 1207 | $this->parentHref = ''; |
1208 | 1208 | |
1209 | 1209 | // Get the closest ancestor of the current document which has a MPTR child. |
1210 | - $parentMptr = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="' . $this->toplevelId . '"]/ancestor::mets:div[./mets:mptr][1]/mets:mptr'); |
|
1210 | + $parentMptr = $this->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="'.$this->toplevelId.'"]/ancestor::mets:div[./mets:mptr][1]/mets:mptr'); |
|
1211 | 1211 | if (!empty($parentMptr)) { |
1212 | 1212 | $this->parentHref = (string) $parentMptr[0]->attributes('http://www.w3.org/1999/xlink')->href; |
1213 | 1213 | } |
@@ -298,7 +298,7 @@ |
||
298 | 298 | if ($doc !== null) { |
299 | 299 | // Same as MetsDocument::parentHref (TODO: Use it) |
300 | 300 | // Get the closest ancestor of the current document which has a MPTR child. |
301 | - $parentMptr = $doc->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="' . $doc->toplevelId . '"]/ancestor::mets:div[./mets:mptr][1]/mets:mptr'); |
|
301 | + $parentMptr = $doc->mets->xpath('./mets:structMap[@TYPE="LOGICAL"]//mets:div[@ID="'.$doc->toplevelId.'"]/ancestor::mets:div[./mets:mptr][1]/mets:mptr'); |
|
302 | 302 | if (!empty($parentMptr)) { |
303 | 303 | $parentLocation = (string) $parentMptr[0]->attributes('http://www.w3.org/1999/xlink')->href; |
304 | 304 |
@@ -356,7 +356,7 @@ discard block |
||
356 | 356 | |
357 | 357 | $excludeOtherWhere = ''; |
358 | 358 | if ($settings['excludeOther']) { |
359 | - $excludeOtherWhere = 'tx_dlf_documents.pid=' . intval($settings['storagePid']); |
|
359 | + $excludeOtherWhere = 'tx_dlf_documents.pid='.intval($settings['storagePid']); |
|
360 | 360 | } |
361 | 361 | // Check if there are any metadata to suggest. |
362 | 362 | $result = $queryBuilder |
@@ -408,12 +408,12 @@ discard block |
||
408 | 408 | $connection = GeneralUtility::makeInstance(ConnectionPool::class) |
409 | 409 | ->getConnectionForTable('tx_dlf_documents'); |
410 | 410 | |
411 | - $sql = 'SELECT `tx_dlf_documents`.*, GROUP_CONCAT(DISTINCT `tx_dlf_collections`.`oai_name` ORDER BY `tx_dlf_collections`.`oai_name` SEPARATOR " ") AS `collections` ' . |
|
412 | - 'FROM `tx_dlf_documents` ' . |
|
413 | - 'INNER JOIN `tx_dlf_relations` ON `tx_dlf_relations`.`uid_local` = `tx_dlf_documents`.`uid` ' . |
|
414 | - 'INNER JOIN `tx_dlf_collections` ON `tx_dlf_collections`.`uid` = `tx_dlf_relations`.`uid_foreign` ' . |
|
415 | - 'WHERE `tx_dlf_documents`.`record_id` = ? ' . |
|
416 | - 'AND `tx_dlf_relations`.`ident`="docs_colls" ' . |
|
411 | + $sql = 'SELECT `tx_dlf_documents`.*, GROUP_CONCAT(DISTINCT `tx_dlf_collections`.`oai_name` ORDER BY `tx_dlf_collections`.`oai_name` SEPARATOR " ") AS `collections` '. |
|
412 | + 'FROM `tx_dlf_documents` '. |
|
413 | + 'INNER JOIN `tx_dlf_relations` ON `tx_dlf_relations`.`uid_local` = `tx_dlf_documents`.`uid` '. |
|
414 | + 'INNER JOIN `tx_dlf_collections` ON `tx_dlf_collections`.`uid` = `tx_dlf_relations`.`uid_foreign` '. |
|
415 | + 'WHERE `tx_dlf_documents`.`record_id` = ? '. |
|
416 | + 'AND `tx_dlf_relations`.`ident`="docs_colls" '. |
|
417 | 417 | $where; |
418 | 418 | |
419 | 419 | $values = [ |
@@ -443,13 +443,13 @@ discard block |
||
443 | 443 | $connection = GeneralUtility::makeInstance(ConnectionPool::class) |
444 | 444 | ->getConnectionForTable('tx_dlf_documents'); |
445 | 445 | |
446 | - $sql = 'SELECT `tx_dlf_documents`.*, GROUP_CONCAT(DISTINCT `tx_dlf_collections`.`oai_name` ORDER BY `tx_dlf_collections`.`oai_name` SEPARATOR " ") AS `collections` ' . |
|
447 | - 'FROM `tx_dlf_documents` ' . |
|
448 | - 'INNER JOIN `tx_dlf_relations` ON `tx_dlf_relations`.`uid_local` = `tx_dlf_documents`.`uid` ' . |
|
449 | - 'INNER JOIN `tx_dlf_collections` ON `tx_dlf_collections`.`uid` = `tx_dlf_relations`.`uid_foreign` ' . |
|
450 | - 'WHERE `tx_dlf_documents`.`uid` IN ( ? ) ' . |
|
451 | - 'AND `tx_dlf_relations`.`ident`="docs_colls" ' . |
|
452 | - 'AND ' . Helper::whereExpression('tx_dlf_collections') . ' ' . |
|
446 | + $sql = 'SELECT `tx_dlf_documents`.*, GROUP_CONCAT(DISTINCT `tx_dlf_collections`.`oai_name` ORDER BY `tx_dlf_collections`.`oai_name` SEPARATOR " ") AS `collections` '. |
|
447 | + 'FROM `tx_dlf_documents` '. |
|
448 | + 'INNER JOIN `tx_dlf_relations` ON `tx_dlf_relations`.`uid_local` = `tx_dlf_documents`.`uid` '. |
|
449 | + 'INNER JOIN `tx_dlf_collections` ON `tx_dlf_collections`.`uid` = `tx_dlf_relations`.`uid_foreign` '. |
|
450 | + 'WHERE `tx_dlf_documents`.`uid` IN ( ? ) '. |
|
451 | + 'AND `tx_dlf_relations`.`ident`="docs_colls" '. |
|
452 | + 'AND '.Helper::whereExpression('tx_dlf_collections').' '. |
|
453 | 453 | 'GROUP BY `tx_dlf_documents`.`uid` '; |
454 | 454 | |
455 | 455 | $values = [ |
@@ -12,8 +12,8 @@ |
||
12 | 12 | { |
13 | 13 | parent::setUp(); |
14 | 14 | |
15 | - $this->importDataSet(__DIR__ . '/../../Fixtures/Common/libraries.xml'); |
|
16 | - $this->importDataSet(__DIR__ . '/../../Fixtures/Common/metadata.xml'); |
|
15 | + $this->importDataSet(__DIR__.'/../../Fixtures/Common/libraries.xml'); |
|
16 | + $this->importDataSet(__DIR__.'/../../Fixtures/Common/metadata.xml'); |
|
17 | 17 | } |
18 | 18 | |
19 | 19 | /** |
@@ -11,13 +11,13 @@ |
||
11 | 11 | { |
12 | 12 | parent::setUp(); |
13 | 13 | |
14 | - $this->importDataSet(__DIR__ . '/../../Fixtures/Common/metadata.xml'); |
|
15 | - $this->importDataSet(__DIR__ . '/../../Fixtures/MetsDocument/metadata_mets.xml'); |
|
14 | + $this->importDataSet(__DIR__.'/../../Fixtures/Common/metadata.xml'); |
|
15 | + $this->importDataSet(__DIR__.'/../../Fixtures/MetsDocument/metadata_mets.xml'); |
|
16 | 16 | } |
17 | 17 | |
18 | 18 | protected function doc(string $file) |
19 | 19 | { |
20 | - $url = 'http://web:8001/Tests/Fixtures/MetsDocument/' . $file; |
|
20 | + $url = 'http://web:8001/Tests/Fixtures/MetsDocument/'.$file; |
|
21 | 21 | $doc = Doc::getInstance($url); |
22 | 22 | $this->assertNotNull($doc); |
23 | 23 | return $doc; |
@@ -48,8 +48,8 @@ |
||
48 | 48 | |
49 | 49 | $settingsParts = explode("/", $model); |
50 | 50 | $fileName = end($settingsParts); |
51 | - $path = substr($model, 0, strrpos($model, $fileName)); |
|
52 | - $modelSettings = $path . "metadata/" . $fileName . "_viewer"; |
|
51 | + $path = substr($model, 0, strrpos($model, $fileName)); |
|
52 | + $modelSettings = $path."metadata/".$fileName."_viewer"; |
|
53 | 53 | |
54 | 54 | if (!empty($modelConverted)) { |
55 | 55 | $model = $modelConverted; |
@@ -52,12 +52,12 @@ |
||
52 | 52 | $(document).ready(function() { |
53 | 53 | AudioPlayer = new dlfAudioPlayer({ |
54 | 54 | audio: { |
55 | - mimeType: "' . $this->audio['mimetype'] . '", |
|
56 | - title: "' . $this->audio['label'] . '", |
|
57 | - url: "' . $this->audio['url'] . '" |
|
55 | + mimeType: "' . $this->audio['mimetype'].'", |
|
56 | + title: "' . $this->audio['label'].'", |
|
57 | + url: "' . $this->audio['url'].'" |
|
58 | 58 | }, |
59 | 59 | parentElId: "tx-dlf-audio", |
60 | - swfPath: "' . PathUtility::stripPathSitePrefix(ExtensionManagementUtility::extPath('dlf')) . 'Resources/Public/JavaScript/jPlayer/jquery.jplayer.swf" |
|
60 | + swfPath: "' . PathUtility::stripPathSitePrefix(ExtensionManagementUtility::extPath('dlf')).'Resources/Public/JavaScript/jPlayer/jquery.jplayer.swf" |
|
61 | 61 | }); |
62 | 62 | }); |
63 | 63 | '; |