@@ -49,22 +49,22 @@ discard block |
||
| 49 | 49 | ], |
| 50 | 50 | 'insertClipboard' => [ |
| 51 | 51 | 'renderType' => 'insertClipboard', |
| 52 | - 'after' => [ 'elementBrowser' ], |
|
| 52 | + 'after' => ['elementBrowser'], |
|
| 53 | 53 | ], |
| 54 | 54 | 'editPopup' => [ |
| 55 | 55 | 'renderType' => 'editPopup', |
| 56 | 56 | 'disabled' => true, |
| 57 | - 'after' => [ 'insertClipboard' ], |
|
| 57 | + 'after' => ['insertClipboard'], |
|
| 58 | 58 | ], |
| 59 | 59 | 'addRecord' => [ |
| 60 | 60 | 'renderType' => 'addRecord', |
| 61 | 61 | 'disabled' => true, |
| 62 | - 'after' => [ 'editPopup' ], |
|
| 62 | + 'after' => ['editPopup'], |
|
| 63 | 63 | ], |
| 64 | 64 | 'listModule' => [ |
| 65 | 65 | 'renderType' => 'listModule', |
| 66 | 66 | 'disabled' => true, |
| 67 | - 'after' => [ 'addRecord' ], |
|
| 67 | + 'after' => ['addRecord'], |
|
| 68 | 68 | ], |
| 69 | 69 | ]; |
| 70 | 70 | |
@@ -79,19 +79,19 @@ discard block |
||
| 79 | 79 | ], |
| 80 | 80 | 'recordsOverview' => [ |
| 81 | 81 | 'renderType' => 'recordsOverview', |
| 82 | - 'after' => [ 'tableList' ], |
|
| 82 | + 'after' => ['tableList'], |
|
| 83 | 83 | ], |
| 84 | 84 | 'localizationStateSelector' => [ |
| 85 | 85 | 'renderType' => 'localizationStateSelector', |
| 86 | - 'after' => [ 'recordsOverview' ], |
|
| 86 | + 'after' => ['recordsOverview'], |
|
| 87 | 87 | ], |
| 88 | 88 | 'otherLanguageContent' => [ |
| 89 | 89 | 'renderType' => 'otherLanguageContent', |
| 90 | - 'after' => [ 'localizationStateSelector' ], |
|
| 90 | + 'after' => ['localizationStateSelector'], |
|
| 91 | 91 | ], |
| 92 | 92 | 'defaultLanguageDifferences' => [ |
| 93 | 93 | 'renderType' => 'defaultLanguageDifferences', |
| 94 | - 'after' => [ 'otherLanguageContent' ], |
|
| 94 | + 'after' => ['otherLanguageContent'], |
|
| 95 | 95 | ], |
| 96 | 96 | ]; |
| 97 | 97 | |
@@ -171,21 +171,21 @@ discard block |
||
| 171 | 171 | // Return early if element is read only |
| 172 | 172 | $html = []; |
| 173 | 173 | $html[] = '<div class="formengine-field-item t3js-formengine-field-item">'; |
| 174 | - $html[] = $fieldInformationHtml; |
|
| 175 | - $html[] = '<div class="form-wizards-wrap">'; |
|
| 176 | - $html[] = '<div class="form-wizards-element">'; |
|
| 177 | - $html[] = '<select'; |
|
| 178 | - $html[] = ' size="' . $size . '"'; |
|
| 179 | - $html[] = ' disabled="disabled"'; |
|
| 180 | - $html[] = ' class="form-select"'; |
|
| 181 | - $html[] = ($maxItems !== 1 && $size !== 1) ? ' multiple="multiple"' : ''; |
|
| 182 | - $html[] = '>'; |
|
| 183 | - $html[] = implode(LF, $selectorOptionsHtml); |
|
| 184 | - $html[] = '</select>'; |
|
| 185 | - $html[] = '</div>'; |
|
| 186 | - $html[] = '<div class="form-wizards-items-aside">'; |
|
| 187 | - $html[] = '</div>'; |
|
| 188 | - $html[] = '</div>'; |
|
| 174 | + $html[] = $fieldInformationHtml; |
|
| 175 | + $html[] = '<div class="form-wizards-wrap">'; |
|
| 176 | + $html[] = '<div class="form-wizards-element">'; |
|
| 177 | + $html[] = '<select'; |
|
| 178 | + $html[] = ' size="' . $size . '"'; |
|
| 179 | + $html[] = ' disabled="disabled"'; |
|
| 180 | + $html[] = ' class="form-select"'; |
|
| 181 | + $html[] = ($maxItems !== 1 && $size !== 1) ? ' multiple="multiple"' : ''; |
|
| 182 | + $html[] = '>'; |
|
| 183 | + $html[] = implode(LF, $selectorOptionsHtml); |
|
| 184 | + $html[] = '</select>'; |
|
| 185 | + $html[] = '</div>'; |
|
| 186 | + $html[] = '<div class="form-wizards-items-aside">'; |
|
| 187 | + $html[] = '</div>'; |
|
| 188 | + $html[] = '</div>'; |
|
| 189 | 189 | $html[] = '</div>'; |
| 190 | 190 | $resultArray['html'] = implode(LF, $html); |
| 191 | 191 | return $resultArray; |
@@ -264,105 +264,105 @@ discard block |
||
| 264 | 264 | |
| 265 | 265 | $html = []; |
| 266 | 266 | $html[] = '<div class="formengine-field-item t3js-formengine-field-item">'; |
| 267 | - $html[] = $fieldInformationHtml; |
|
| 268 | - $html[] = '<div class="form-wizards-wrap">'; |
|
| 267 | + $html[] = $fieldInformationHtml; |
|
| 268 | + $html[] = '<div class="form-wizards-wrap">'; |
|
| 269 | 269 | if ($internalType === 'db' && (!isset($config['hideSuggest']) || (bool)$config['hideSuggest'] !== true)) { |
| 270 | - $html[] = '<div class="form-wizards-items-top">'; |
|
| 271 | - $html[] = '<div class="autocomplete t3-form-suggest-container">'; |
|
| 272 | - $html[] = '<div class="input-group">'; |
|
| 273 | - $html[] = '<span class="input-group-addon">'; |
|
| 274 | - $html[] = $this->iconFactory->getIcon('actions-search', Icon::SIZE_SMALL)->render(); |
|
| 275 | - $html[] = '</span>'; |
|
| 276 | - $html[] = '<input type="search" class="t3-form-suggest form-control"'; |
|
| 277 | - $html[] = ' placeholder="' . $languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.findRecord') . '"'; |
|
| 278 | - $html[] = ' data-fieldname="' . htmlspecialchars($fieldName) . '"'; |
|
| 279 | - $html[] = ' data-tablename="' . htmlspecialchars($table) . '"'; |
|
| 280 | - $html[] = ' data-field="' . htmlspecialchars($elementName) . '"'; |
|
| 281 | - $html[] = ' data-uid="' . htmlspecialchars($this->data['databaseRow']['uid']) . '"'; |
|
| 282 | - $html[] = ' data-pid="' . htmlspecialchars($this->data['parentPageRow']['uid'] ?? 0) . '"'; |
|
| 283 | - $html[] = ' data-fieldtype="' . htmlspecialchars($config['type']) . '"'; |
|
| 284 | - $html[] = ' data-minchars="' . htmlspecialchars((string)$suggestMinimumCharacters) . '"'; |
|
| 285 | - $html[] = ' data-datastructureidentifier="' . htmlspecialchars($dataStructureIdentifier) . '"'; |
|
| 286 | - $html[] = ' data-flexformsheetname="' . htmlspecialchars($flexFormSheetName) . '"'; |
|
| 287 | - $html[] = ' data-flexformfieldname="' . htmlspecialchars($flexFormFieldName) . '"'; |
|
| 288 | - $html[] = ' data-flexformcontainername="' . htmlspecialchars($flexFormContainerName) . '"'; |
|
| 289 | - $html[] = ' data-flexformcontainerfieldname="' . htmlspecialchars($flexFormContainerFieldName) . '"'; |
|
| 290 | - $html[] = '/>'; |
|
| 291 | - $html[] = '</div>'; |
|
| 292 | - $html[] = '</div>'; |
|
| 293 | - $html[] = '</div>'; |
|
| 270 | + $html[] = '<div class="form-wizards-items-top">'; |
|
| 271 | + $html[] = '<div class="autocomplete t3-form-suggest-container">'; |
|
| 272 | + $html[] = '<div class="input-group">'; |
|
| 273 | + $html[] = '<span class="input-group-addon">'; |
|
| 274 | + $html[] = $this->iconFactory->getIcon('actions-search', Icon::SIZE_SMALL)->render(); |
|
| 275 | + $html[] = '</span>'; |
|
| 276 | + $html[] = '<input type="search" class="t3-form-suggest form-control"'; |
|
| 277 | + $html[] = ' placeholder="' . $languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.findRecord') . '"'; |
|
| 278 | + $html[] = ' data-fieldname="' . htmlspecialchars($fieldName) . '"'; |
|
| 279 | + $html[] = ' data-tablename="' . htmlspecialchars($table) . '"'; |
|
| 280 | + $html[] = ' data-field="' . htmlspecialchars($elementName) . '"'; |
|
| 281 | + $html[] = ' data-uid="' . htmlspecialchars($this->data['databaseRow']['uid']) . '"'; |
|
| 282 | + $html[] = ' data-pid="' . htmlspecialchars($this->data['parentPageRow']['uid'] ?? 0) . '"'; |
|
| 283 | + $html[] = ' data-fieldtype="' . htmlspecialchars($config['type']) . '"'; |
|
| 284 | + $html[] = ' data-minchars="' . htmlspecialchars((string)$suggestMinimumCharacters) . '"'; |
|
| 285 | + $html[] = ' data-datastructureidentifier="' . htmlspecialchars($dataStructureIdentifier) . '"'; |
|
| 286 | + $html[] = ' data-flexformsheetname="' . htmlspecialchars($flexFormSheetName) . '"'; |
|
| 287 | + $html[] = ' data-flexformfieldname="' . htmlspecialchars($flexFormFieldName) . '"'; |
|
| 288 | + $html[] = ' data-flexformcontainername="' . htmlspecialchars($flexFormContainerName) . '"'; |
|
| 289 | + $html[] = ' data-flexformcontainerfieldname="' . htmlspecialchars($flexFormContainerFieldName) . '"'; |
|
| 290 | + $html[] = '/>'; |
|
| 291 | + $html[] = '</div>'; |
|
| 292 | + $html[] = '</div>'; |
|
| 293 | + $html[] = '</div>'; |
|
| 294 | 294 | } |
| 295 | - $html[] = '<div class="form-wizards-element">'; |
|
| 296 | - $html[] = '<input type="hidden" class="t3js-group-hidden-field" data-formengine-input-name="' . htmlspecialchars($elementName) . '" value="' . $itemCanBeSelectedMoreThanOnce . '" />'; |
|
| 297 | - $html[] = '<select ' . GeneralUtility::implodeAttributes($selectorAttributes, true) . '>'; |
|
| 298 | - $html[] = implode(LF, $selectorOptionsHtml); |
|
| 299 | - $html[] = '</select>'; |
|
| 300 | - $html[] = '</div>'; |
|
| 301 | - $html[] = '<div class="form-wizards-items-aside">'; |
|
| 302 | - $html[] = '<div class="btn-group-vertical">'; |
|
| 303 | - if ($maxItems > 1 && $size >=5 && $showMoveIcons) { |
|
| 304 | - $html[] = '<a href="#"'; |
|
| 305 | - $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-top"'; |
|
| 306 | - $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 307 | - $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_to_top')) . '"'; |
|
| 308 | - $html[] = '>'; |
|
| 309 | - $html[] = $this->iconFactory->getIcon('actions-move-to-top', Icon::SIZE_SMALL)->render(); |
|
| 310 | - $html[] = '</a>'; |
|
| 295 | + $html[] = '<div class="form-wizards-element">'; |
|
| 296 | + $html[] = '<input type="hidden" class="t3js-group-hidden-field" data-formengine-input-name="' . htmlspecialchars($elementName) . '" value="' . $itemCanBeSelectedMoreThanOnce . '" />'; |
|
| 297 | + $html[] = '<select ' . GeneralUtility::implodeAttributes($selectorAttributes, true) . '>'; |
|
| 298 | + $html[] = implode(LF, $selectorOptionsHtml); |
|
| 299 | + $html[] = '</select>'; |
|
| 300 | + $html[] = '</div>'; |
|
| 301 | + $html[] = '<div class="form-wizards-items-aside">'; |
|
| 302 | + $html[] = '<div class="btn-group-vertical">'; |
|
| 303 | + if ($maxItems > 1 && $size >= 5 && $showMoveIcons) { |
|
| 304 | + $html[] = '<a href="#"'; |
|
| 305 | + $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-top"'; |
|
| 306 | + $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 307 | + $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_to_top')) . '"'; |
|
| 308 | + $html[] = '>'; |
|
| 309 | + $html[] = $this->iconFactory->getIcon('actions-move-to-top', Icon::SIZE_SMALL)->render(); |
|
| 310 | + $html[] = '</a>'; |
|
| 311 | 311 | } |
| 312 | 312 | if ($maxItems > 1 && $size > 1 && $showMoveIcons) { |
| 313 | - $html[] = '<a href="#"'; |
|
| 314 | - $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-up"'; |
|
| 315 | - $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 316 | - $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_up')) . '"'; |
|
| 317 | - $html[] = '>'; |
|
| 318 | - $html[] = $this->iconFactory->getIcon('actions-move-up', Icon::SIZE_SMALL)->render(); |
|
| 319 | - $html[] = '</a>'; |
|
| 320 | - $html[] = '<a href="#"'; |
|
| 321 | - $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-down"'; |
|
| 322 | - $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 323 | - $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_down')) . '"'; |
|
| 324 | - $html[] = '>'; |
|
| 325 | - $html[] = $this->iconFactory->getIcon('actions-move-down', Icon::SIZE_SMALL)->render(); |
|
| 326 | - $html[] = '</a>'; |
|
| 313 | + $html[] = '<a href="#"'; |
|
| 314 | + $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-up"'; |
|
| 315 | + $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 316 | + $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_up')) . '"'; |
|
| 317 | + $html[] = '>'; |
|
| 318 | + $html[] = $this->iconFactory->getIcon('actions-move-up', Icon::SIZE_SMALL)->render(); |
|
| 319 | + $html[] = '</a>'; |
|
| 320 | + $html[] = '<a href="#"'; |
|
| 321 | + $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-down"'; |
|
| 322 | + $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 323 | + $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_down')) . '"'; |
|
| 324 | + $html[] = '>'; |
|
| 325 | + $html[] = $this->iconFactory->getIcon('actions-move-down', Icon::SIZE_SMALL)->render(); |
|
| 326 | + $html[] = '</a>'; |
|
| 327 | 327 | } |
| 328 | 328 | if ($maxItems > 1 && $size >= 5 && $showMoveIcons) { |
| 329 | - $html[] = '<a href="#"'; |
|
| 330 | - $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-bottom"'; |
|
| 331 | - $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 332 | - $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_to_bottom')) . '"'; |
|
| 333 | - $html[] = '>'; |
|
| 334 | - $html[] = $this->iconFactory->getIcon('actions-move-to-bottom', Icon::SIZE_SMALL)->render(); |
|
| 335 | - $html[] = '</a>'; |
|
| 329 | + $html[] = '<a href="#"'; |
|
| 330 | + $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-moveoption-bottom"'; |
|
| 331 | + $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 332 | + $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.move_to_bottom')) . '"'; |
|
| 333 | + $html[] = '>'; |
|
| 334 | + $html[] = $this->iconFactory->getIcon('actions-move-to-bottom', Icon::SIZE_SMALL)->render(); |
|
| 335 | + $html[] = '</a>'; |
|
| 336 | 336 | } |
| 337 | 337 | if ($showDeleteControl) { |
| 338 | - $html[] = '<a href="#"'; |
|
| 339 | - $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-removeoption t3js-revert-unique"'; |
|
| 340 | - $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 341 | - $html[] = ' data-uid="' . htmlspecialchars($row['uid']) . '"'; |
|
| 342 | - $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.remove_selected')) . '"'; |
|
| 343 | - $html[] = '>'; |
|
| 344 | - $html[] = $this->iconFactory->getIcon('actions-selection-delete', Icon::SIZE_SMALL)->render(); |
|
| 345 | - $html[] = '</a>'; |
|
| 338 | + $html[] = '<a href="#"'; |
|
| 339 | + $html[] = ' class="btn btn-default t3js-btn-option t3js-btn-removeoption t3js-revert-unique"'; |
|
| 340 | + $html[] = ' data-fieldname="' . htmlspecialchars($elementName) . '"'; |
|
| 341 | + $html[] = ' data-uid="' . htmlspecialchars($row['uid']) . '"'; |
|
| 342 | + $html[] = ' title="' . htmlspecialchars($languageService->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.remove_selected')) . '"'; |
|
| 343 | + $html[] = '>'; |
|
| 344 | + $html[] = $this->iconFactory->getIcon('actions-selection-delete', Icon::SIZE_SMALL)->render(); |
|
| 345 | + $html[] = '</a>'; |
|
| 346 | 346 | } |
| 347 | - $html[] = '</div>'; |
|
| 348 | - $html[] = '</div>'; |
|
| 349 | - $html[] = '<div class="form-wizards-items-aside">'; |
|
| 350 | - $html[] = '<div class="btn-group-vertical">'; |
|
| 351 | - $html[] = $fieldControlHtml; |
|
| 352 | - $html[] = '</div>'; |
|
| 353 | - $html[] = '</div>'; |
|
| 347 | + $html[] = '</div>'; |
|
| 348 | + $html[] = '</div>'; |
|
| 349 | + $html[] = '<div class="form-wizards-items-aside">'; |
|
| 350 | + $html[] = '<div class="btn-group-vertical">'; |
|
| 351 | + $html[] = $fieldControlHtml; |
|
| 352 | + $html[] = '</div>'; |
|
| 353 | + $html[] = '</div>'; |
|
| 354 | 354 | if (!empty($fieldWizardHtml)) { |
| 355 | 355 | $html[] = '<div class="form-wizards-items-bottom">'; |
| 356 | 356 | $html[] = $fieldWizardHtml; |
| 357 | 357 | $html[] = '</div>'; |
| 358 | 358 | } |
| 359 | - $html[] = '</div>'; |
|
| 360 | - $html[] = '<input type="hidden"'; |
|
| 361 | - $html[] = ' data-formengine-validation-rules="' . htmlspecialchars($this->getValidationDataAsJsonString($config)) . '"'; |
|
| 362 | - $html[] = ' name="' . htmlspecialchars($elementName) . '"'; |
|
| 363 | - $html[] = ' value="' . htmlspecialchars(implode(',', $listOfSelectedValues)) . '"'; |
|
| 364 | - $html[] = ' onchange="' . htmlspecialchars(implode('', $parameterArray['fieldChangeFunc'])) . '"'; |
|
| 365 | - $html[] = ' />'; |
|
| 359 | + $html[] = '</div>'; |
|
| 360 | + $html[] = '<input type="hidden"'; |
|
| 361 | + $html[] = ' data-formengine-validation-rules="' . htmlspecialchars($this->getValidationDataAsJsonString($config)) . '"'; |
|
| 362 | + $html[] = ' name="' . htmlspecialchars($elementName) . '"'; |
|
| 363 | + $html[] = ' value="' . htmlspecialchars(implode(',', $listOfSelectedValues)) . '"'; |
|
| 364 | + $html[] = ' onchange="' . htmlspecialchars(implode('', $parameterArray['fieldChangeFunc'])) . '"'; |
|
| 365 | + $html[] = ' />'; |
|
| 366 | 366 | $html[] = '</div>'; |
| 367 | 367 | |
| 368 | 368 | $resultArray['requireJsModules'][] = ['TYPO3/CMS/Backend/FormEngine/Element/GroupElement' => ' |