[TASK] Add both form as list plugin seperate

This commit is contained in:
Benjamin Serfhos 2018-10-04 13:01:31 +02:00
parent d0bbfb8682
commit de5261f7d4
22 changed files with 304 additions and 119 deletions

View file

@ -47,7 +47,7 @@ class ConfigurationContainer implements ConfigurationContainerInterface
$this->settings = $configurationManager->getConfiguration(
ConfigurationManagerInterface::CONFIGURATION_TYPE_SETTINGS,
'SearchCore',
'search'
'Results'
);
if ($this->settings === null) {
throw new NoConfigurationException('Could not fetch configuration.', 1484226842);

View file

@ -68,12 +68,31 @@ class SearchController extends ActionController
}
/**
* Process a search and deliver original request and result to view.
* Action: Search form
*
* @param SearchRequest $searchRequest
* @return void
*/
public function searchAction(SearchRequest $searchRequest = null)
public function formAction(SearchRequest $searchRequest = null)
{
$searchResult = null;
if ($searchRequest !== null) {
$searchResult = $this->searchService->search($searchRequest);
}
$this->view->assignMultiple([
'searchRequest' => $searchRequest,
'searchResult' => $searchResult,
]);
}
/**
* Action: Display list results and deliver original request and result to view.
*
* @param SearchRequest $searchRequest
* @return void
*/
public function resultsAction(SearchRequest $searchRequest = null)
{
$searchResult = null;
if ($searchRequest !== null) {

View file

@ -1,12 +1,25 @@
<?php
use TYPO3\CMS\Extbase\Utility\ExtensionUtility;
call_user_func(function ($extension, $table) {
$plugin = TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
$plugin = ExtensionUtility::registerPlugin(
'Codappix.' . $extension,
'search',
'Search Core',
'EXT:search_core/Resources/Public/Icons/Plugin.svg'
) ?? 'searchcore_search';
'Results',
'LLL:EXT:search_core/Resources/Private/Language/locallang_be.xlf:plugin.results.title',
'EXT:search_core/Resources/Public/Icons/PluginResults.svg'
) ?? 'searchcore_results';
$GLOBALS['TCA'][$table]['types']['list']['subtypes_excludelist'][$plugin] = 'recursive,pages';
$plugin = ExtensionUtility::registerPlugin(
'Codappix.' . $extension,
'Form',
'LLL:EXT:search_core/Resources/Private/Language/locallang_be.xlf:plugin.form.title',
'EXT:search_core/Resources/Public/Icons/PluginForm.svg'
) ?? 'searchcore_form';
$GLOBALS['TCA'][$table]['types']['list']['subtypes_excludelist'][$plugin] = 'recursive,pages';
}, 'search_core', 'tt_content');

View file

@ -0,0 +1,24 @@
# dummy placeholders for item groups
mod.wizards.newContentElement.wizardItems.plugins {
elements {
searchcore_form {
title = LLL:EXT:search_core/Resources/Private/Language/locallang_be.xlf:plugin.form.title
description = LLL:EXT:search_core/Resources/Private/Language/locallang_be.xlf:plugin.form.description
iconIdentifier = plugin-search_core-form
tt_content_defValues {
CType = list
list_type = searchcore_form
}
}
searchcore_results {
title = LLL:EXT:search_core/Resources/Private/Language/locallang_be.xlf:plugin.results.title
description = LLL:EXT:search_core/Resources/Private/Language/locallang_be.xlf:plugin.results.description
iconIdentifier = plugin-search_core-results
tt_content_defValues {
CType = list
list_type = searchcore_results
}
}
}
}

View file

@ -1,25 +0,0 @@
plugin {
tx_searchcore {
settings {
connections {
elasticsearch {
host = localhost
port = 9200
index = typo3content
}
}
indexing {
tt_content {
additionalWhereClause = tt_content.CType NOT IN ('gridelements_pi1', 'list', 'div', 'menu', 'shortcut', 'search', 'login') AND (tt_content.bodytext != '' OR tt_content.header != '')
}
pages {
additionalWhereClause = pages.doktype NOT IN (3, 199, 6, 254, 255)
abstractFields = abstract, description, bodytext
contentFields = header, bodytext
}
}
}
}
}

View file

@ -0,0 +1,30 @@
plugin.tx_searchcore {
view {
templateRootPath = EXT:search_core/Resources/Private/Templates
partialRootPath = EXT:search_core/Resources/Private/Partials
layoutRootPath = EXT:search_core/Resources/Private/Layouts
}
settings {
searchOverview =
connections {
elasticsearch {
host = localhost
port = 9200
index = typo3content
}
}
indexing {
tt_content {
additionalWhereClause = tt_content.CType NOT IN ('gridelements_pi1', 'list', 'div', 'menu', 'shortcut', 'search', 'login') AND (tt_content.bodytext != '' OR tt_content.header != '')
}
pages {
additionalWhereClause = pages.doktype NOT IN (3, 199, 6, 254, 255)
abstractFields = abstract, description, bodytext
contentFields = header, bodytext
}
}
}
}

View file

@ -1,37 +0,0 @@
plugin {
tx_searchcore {
settings {
connections {
elasticsearch {
host = {$plugin.tx_searchcore.settings.connections.elasticsearch.host}
port = {$plugin.tx_searchcore.settings.connections.elasticsearch.port}
index = {$plugin.tx_searchcore.settings.connections.elasticsearch.index}
}
}
indexing {
# Not for direct indexing therefore no indexer.
# Used to configure tt_content fetching while indexing pages
tt_content {
additionalWhereClause = {$plugin.tx_searchcore.settings.indexing.tt_content.additionalWhereClause}
}
pages {
indexer = Codappix\SearchCore\Domain\Index\TcaIndexer\PagesIndexer
additionalWhereClause = {$plugin.tx_searchcore.settings.indexing.pages.additionalWhereClause}
abstractFields = {$plugin.tx_searchcore.settings.indexing.pages.abstractFields}
contentFields = {$plugin.tx_searchcore.settings.indexing.pages.contentFields}
}
}
searching {
fields {
# Default query fields (leave empty for all)
query =
}
}
}
}
}
module.tx_searchcore < plugin.tx_searchcore

View file

@ -0,0 +1,46 @@
plugin.tx_searchcore {
view {
# This sets the plugin namespace of all your plugins inside the extension to "tx_searchcore",
# making it possible to directly access search_core parameters in your controller:
pluginNamespace = tx_searchcore
templateRootPaths.10 = {$plugin.tx_searchcore.view.templateRootPath}
partialRootPaths.10 = {$plugin.tx_searchcore.view.partialRootPath}
layoutRootPaths.10 = {$plugin.tx_searchcore.view.layoutRootPath}
}
settings {
searchOverview = {$plugin.tx_searchcore.settings.searchOverview}
connections {
elasticsearch {
host = {$plugin.tx_searchcore.settings.connections.elasticsearch.host}
port = {$plugin.tx_searchcore.settings.connections.elasticsearch.port}
index = {$plugin.tx_searchcore.settings.connections.elasticsearch.index}
}
}
indexing {
# Not for direct indexing therefore no indexer.
# Used to configure tt_content fetching while indexing pages
tt_content {
additionalWhereClause = {$plugin.tx_searchcore.settings.indexing.tt_content.additionalWhereClause}
}
pages {
indexer = Codappix\SearchCore\Domain\Index\TcaIndexer\PagesIndexer
additionalWhereClause = {$plugin.tx_searchcore.settings.indexing.pages.additionalWhereClause}
abstractFields = {$plugin.tx_searchcore.settings.indexing.pages.abstractFields}
contentFields = {$plugin.tx_searchcore.settings.indexing.pages.contentFields}
}
}
searching {
fields {
# Default query fields (leave empty for all)
query =
}
}
}
}
module.tx_searchcore.settings < plugin.tx_searchcore.settings

View file

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<xliff version="1.0">
<file source-language="en" datatype="plaintext" original="messages">
<header/>
<body>
<trans-unit id="no_results_found">
<source>Please enter your search term in the box above.</source>
</trans-unit>
<trans-unit id="no_results_found_with_search">
<source>No results found with given search query (%s).</source>
</trans-unit>
</body>
</file>
</xliff>

View file

@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<xliff version="1.0">
<file source-language="en" datatype="plaintext" original="messages">
<header/>
<body>
<trans-unit id="plugin.results.title">
<source>Search Core: Results</source>
</trans-unit>
<trans-unit id="plugin.results.description">
<source>List results from search</source>
</trans-unit>
<trans-unit id="plugin.form.title">
<source>Search Core: Form</source>
</trans-unit>
<trans-unit id="plugin.form.description">
<source>Just a search form to list page</source>
</trans-unit>
</body>
</file>
</xliff>

View file

@ -0,0 +1,6 @@
<html xmlns:f="http://xsd.helmut-hummel.de/ns/TYPO3/CMS/Fluid/ViewHelpers"
data-namespace-typo3-fluid="true">
<div class="search-core">
<f:render section="Content"/>
</div>
</html>

View file

@ -0,0 +1,9 @@
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
data-namespace-typo3-fluid="true">
<f:form name="searchRequest" object="{searchRequest}">
<f:form.textfield property="query"/>
<f:form.submit value="search"/>
</f:form>
</html>

View file

@ -0,0 +1,8 @@
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
data-namespace-typo3-fluid="true">
<f:link.typolink parameter="{result.plainData.search_page_typolink}">
[{result.type}:{result.plainData.uid}] - {result.plainData.search_title}
</f:link.typolink>
</html>

View file

@ -0,0 +1,11 @@
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
data-namespace-typo3-fluid="true">
<f:layout name="Default"/>
<f:section name="Content">
<div class="core-search-form">
<f:render partial="Form/SearchRequest" arguments="{searchRequest: searchRequest, result: result}"/>
</div>
</f:section>
</html>

View file

@ -0,0 +1,25 @@
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
data-namespace-typo3-fluid="true">
<f:layout name="Default"/>
<f:section name="Content">
<f:if condition="{searchResult}">
<f:then>
<ul class="core-search-results">
<f:for each="{searchResult}" as="result">
<li>
<f:render partial="Results/ListItem" arguments="{searchRequest: searchRequest, result: result}"/>
</li>
</f:for>
</ul>
</f:then>
<f:else>
<f:if condition="{searchRequest.searchTerm}">
<f:then>{f:translate(key: 'no_results_found_with_search', arguments: '{0: searchRequest.searchTerm}')}</f:then>
<f:else>{f:translate(key: 'no_results_found')}</f:else>
</f:if>
</f:else>
</f:if>
</f:section>
</html>

View file

@ -1,20 +0,0 @@
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
data-namespace-typo3-fluid="true">
<div class="core-search">
<f:form name="searchRequest" object="{searchRequest}">
<f:form.textfield property="query"/>
<f:form.submit value="search"/>
</f:form>
<ul>
<f:for each="{searchResult}" as="result">
<li>
<f:link.typolink parameter="{result.plainData.search_page_typolink}">
[{result.type}:{result.plainData.uid}] - {result.plainData.search_title}
</f:link.typolink>
</li>
</f:for>
</ul>
</div>
</html>

View file

@ -0,0 +1,10 @@
<svg viewBox="0 0 700 700" xmlns="http://www.w3.org/2000/svg">
<path d="M498.406 297.9c0 24.717-15.866 46.983-38.942 55.303a44.454 44.454 0 0 1 2.783 15.521c0 24.546-19.97 44.51-44.516 44.51-9.91 0-19.468-3.37-27.284-9.506-15.702 21.921-40.818 34.93-67.9 34.93-46.137 0-83.668-37.533-83.668-83.67 0-5.408.54-10.757 1.53-15.942-23.316-8.4-38.815-30.247-38.815-55.25 0-24.719 15.867-46.978 38.942-55.305a44.41 44.41 0 0 1-2.783-15.513c0-24.547 19.97-44.516 44.516-44.516a44.35 44.35 0 0 1 27.247 9.324C325.308 155.956 350.439 143 377.453 143c46.249 0 83.87 37.622 83.87 83.864 0 5.461-.531 10.705-1.552 15.95 23.21 8.461 38.635 30.21 38.635 55.085z" fill="#FEFEFE"/>
<path d="M318.287 270.333l64.946 29.608 65.527-57.415a72.526 72.526 0 0 0 1.412-14.4c0-40.397-32.86-73.264-73.256-73.264-24.167 0-46.708 11.9-60.41 31.852l-10.898 56.548 12.679 27.07z" fill="#FED10C"/>
<path d="M251.06 339.108a74.537 74.537 0 0 0-1.435 14.621c0 40.5 32.955 73.455 73.462 73.455 24.365 0 47.017-12.01 60.696-32.168l10.818-56.356-14.437-27.587-65.203-29.718-63.902 57.753z" fill="#22B9AF"/>
<path d="M250.648 226.714l44.508 10.51 9.752-50.606a35.146 35.146 0 0 0-21.313-7.193c-19.342 0-35.072 15.74-35.072 35.081 0 4.272.713 8.37 2.125 12.208" fill="#EE5097"/>
<path d="M246.784 237.315c-19.886 6.589-33.712 25.652-33.712 46.619 0 20.416 12.627 38.647 31.579 45.862l62.446-56.445-11.465-24.497-48.848-11.54z" fill="#15A6DF"/>
<path d="M395.2 395.014c6.104 4.692 13.576 7.251 21.203 7.251 19.34 0 35.072-15.73 35.072-35.072 0-4.265-.713-8.361-2.125-12.2l-44.472-10.407-9.678 50.428z" fill="#91C63F"/>
<path d="M404.249 332.929l48.958 11.45c19.894-6.574 33.72-25.644 33.72-46.618 0-20.38-12.657-38.59-31.646-45.781l-64.034 56.098 13.002 24.85z" fill="#0979A0"/>
<path d="M224.658 517.907c0-8.176-1.312-13.952-3.933-17.33-2.622-3.377-6.888-5.066-12.797-5.066-5.912 0-10.354 1.779-13.33 5.333-2.98 3.555-4.513 9.243-4.6 17.063h34.66zm3.6 28.927l3.865-.4.267 7.867c-10.13 1.419-18.796 2.132-25.995 2.132-9.598 0-16.397-2.776-20.397-8.332C182 542.548 180 533.904 180 522.173c0-23.373 9.285-35.06 27.861-35.06 8.976 0 15.685 2.51 20.13 7.53 4.443 5.023 6.665 12.912 6.665 23.663l-.533 7.599h-43.992c0 7.378 1.333 12.844 4 16.397 2.666 3.556 7.308 5.333 13.93 5.333 6.62 0 13.352-.267 20.196-.801zm20.341 9.084h9.998v-87.742h-9.998zm31.902-20.148c0 8.178 3.377 12.265 10.131 12.265 6.043 0 11.998-1.021 17.864-3.066l3.066-1.068v-21.995l-19.73 1.866c-3.999.357-6.888 1.512-8.664 3.466-1.78 1.956-2.667 4.799-2.667 8.532m41.06-27.195v33.623c0 3.332 8.296 3.199 8.296 3.199l-.51 8.833c-7.022 0-12.836.583-16.328-2.794-7.999 3.555-15.987 4.997-23.986 4.997-6.133 0-10.798-1.733-13.997-5.2-3.2-3.465-4.8-8.442-4.8-14.93 0-6.486 1.643-11.264 4.932-14.331 3.288-3.066 8.443-4.952 15.464-5.665l20.93-2v-5.732c0-4.532-.979-7.776-2.933-9.732-1.956-1.953-4.622-2.932-7.998-2.932l-26.27.022v-8.821h25.603c7.553 0 13.041 1.734 16.464 5.199 3.42 3.466 5.132 8.889 5.132 16.264m39.023-12.531c-9.688 0-14.531 3.378-14.531 10.13 0 3.114 1.11 5.313 3.333 6.6 2.22 1.29 7.286 2.623 15.197 3.999 7.909 1.379 13.508 3.313 16.797 5.799 3.287 2.49 4.933 7.156 4.933 13.998 0 6.844-2.2 11.864-6.6 15.063-4.4 3.2-10.82 4.8-19.262 4.8-5.512 0-23.901-2.04-23.901-2.04l.533-8.665c10.57 1.019 18.212 1.773 23.368 1.773 5.153 0 9.085-.821 11.797-2.466 2.71-1.644 4.066-4.4 4.066-8.265 0-3.866-1.156-6.487-3.465-7.865-2.313-1.377-7.38-2.688-15.198-3.933-7.821-1.243-13.377-3.066-16.663-5.466-3.29-2.4-4.933-6.842-4.933-13.331 0-6.486 2.287-11.285 6.865-14.397 4.577-3.11 10.286-4.666 17.13-4.666 5.42 0 24.23 1.379 24.23 1.379v8.717c-9.894-.452-18.01-1.164-23.696-1.164m73.949 1.066h-21.196v31.861c0 7.644.554 12.664 1.667 15.063 1.11 2.401 3.753 3.6 7.931 3.6l11.865-.8.667 8.265c-5.956.977-10.488 1.467-13.599 1.467-6.93 0-11.73-1.687-14.397-5.066-2.666-3.376-3.999-9.819-3.999-19.33v-35.06h-9.465v-8.665h9.465v-20.397h9.865v20.397h21.196v8.665zm13.9 58.808h9.999v-67.473h-9.999v67.473zm0-75.988h9.999v-11.598h-9.999v11.598zm53.304 7.182c2.935 0 7.91.534 14.932 1.6l3.198.4-.4 8.131c-7.11-.799-12.353-1.199-15.73-1.199-7.554 0-12.686 1.8-15.397 5.4-2.712 3.598-4.065 10.263-4.065 19.995 0 9.731 1.267 16.51 3.798 20.33 2.534 3.822 7.8 5.732 15.798 5.732l15.73-1.2.4 8.265c-8.264 1.243-14.442 1.866-18.53 1.866-10.399 0-17.576-2.666-21.529-7.998-3.955-5.332-5.932-14.33-5.932-26.995 0-12.664 2.132-21.55 6.399-26.662 4.265-5.109 11.375-7.665 21.328-7.665" fill="#221E1F"/>
</svg>

After

Width:  |  Height:  |  Size: 4.3 KiB

View file

@ -1,10 +1,10 @@
<svg viewBox="0 0 700 700" xmlns="http://www.w3.org/2000/svg">
<path d="M498.406 297.9c0 24.717-15.866 46.983-38.942 55.303a44.454 44.454 0 0 1 2.783 15.521c0 24.546-19.97 44.51-44.516 44.51-9.91 0-19.468-3.37-27.284-9.506-15.702 21.921-40.818 34.93-67.9 34.93-46.137 0-83.668-37.533-83.668-83.67 0-5.408.54-10.757 1.53-15.942-23.316-8.4-38.815-30.247-38.815-55.25 0-24.719 15.867-46.978 38.942-55.305a44.41 44.41 0 0 1-2.783-15.513c0-24.547 19.97-44.516 44.516-44.516a44.35 44.35 0 0 1 27.247 9.324C325.308 155.956 350.439 143 377.453 143c46.249 0 83.87 37.622 83.87 83.864 0 5.461-.531 10.705-1.552 15.95 23.21 8.461 38.635 30.21 38.635 55.085z" fill="#FEFEFE"/>
<path d="M318.287 270.333l64.946 29.608 65.527-57.415a72.526 72.526 0 0 0 1.412-14.4c0-40.397-32.86-73.264-73.256-73.264-24.167 0-46.708 11.9-60.41 31.852l-10.898 56.548 12.679 27.07z" fill="#FED10C"/>
<path d="M251.06 339.108a74.537 74.537 0 0 0-1.435 14.621c0 40.5 32.955 73.455 73.462 73.455 24.365 0 47.017-12.01 60.696-32.168l10.818-56.356-14.437-27.587-65.203-29.718-63.902 57.753z" fill="#22B9AF"/>
<path d="M250.648 226.714l44.508 10.51 9.752-50.606a35.146 35.146 0 0 0-21.313-7.193c-19.342 0-35.072 15.74-35.072 35.081 0 4.272.713 8.37 2.125 12.208" fill="#EE5097"/>
<path d="M246.784 237.315c-19.886 6.589-33.712 25.652-33.712 46.619 0 20.416 12.627 38.647 31.579 45.862l62.446-56.445-11.465-24.497-48.848-11.54z" fill="#15A6DF"/>
<path d="M395.2 395.014c6.104 4.692 13.576 7.251 21.203 7.251 19.34 0 35.072-15.73 35.072-35.072 0-4.265-.713-8.361-2.125-12.2l-44.472-10.407-9.678 50.428z" fill="#91C63F"/>
<path d="M404.249 332.929l48.958 11.45c19.894-6.574 33.72-25.644 33.72-46.618 0-20.38-12.657-38.59-31.646-45.781l-64.034 56.098 13.002 24.85z" fill="#0979A0"/>
<path d="M224.658 517.907c0-8.176-1.312-13.952-3.933-17.33-2.622-3.377-6.888-5.066-12.797-5.066-5.912 0-10.354 1.779-13.33 5.333-2.98 3.555-4.513 9.243-4.6 17.063h34.66zm3.6 28.927l3.865-.4.267 7.867c-10.13 1.419-18.796 2.132-25.995 2.132-9.598 0-16.397-2.776-20.397-8.332C182 542.548 180 533.904 180 522.173c0-23.373 9.285-35.06 27.861-35.06 8.976 0 15.685 2.51 20.13 7.53 4.443 5.023 6.665 12.912 6.665 23.663l-.533 7.599h-43.992c0 7.378 1.333 12.844 4 16.397 2.666 3.556 7.308 5.333 13.93 5.333 6.62 0 13.352-.267 20.196-.801zm20.341 9.084h9.998v-87.742h-9.998zm31.902-20.148c0 8.178 3.377 12.265 10.131 12.265 6.043 0 11.998-1.021 17.864-3.066l3.066-1.068v-21.995l-19.73 1.866c-3.999.357-6.888 1.512-8.664 3.466-1.78 1.956-2.667 4.799-2.667 8.532m41.06-27.195v33.623c0 3.332 8.296 3.199 8.296 3.199l-.51 8.833c-7.022 0-12.836.583-16.328-2.794-7.999 3.555-15.987 4.997-23.986 4.997-6.133 0-10.798-1.733-13.997-5.2-3.2-3.465-4.8-8.442-4.8-14.93 0-6.486 1.643-11.264 4.932-14.331 3.288-3.066 8.443-4.952 15.464-5.665l20.93-2v-5.732c0-4.532-.979-7.776-2.933-9.732-1.956-1.953-4.622-2.932-7.998-2.932l-26.27.022v-8.821h25.603c7.553 0 13.041 1.734 16.464 5.199 3.42 3.466 5.132 8.889 5.132 16.264m39.023-12.531c-9.688 0-14.531 3.378-14.531 10.13 0 3.114 1.11 5.313 3.333 6.6 2.22 1.29 7.286 2.623 15.197 3.999 7.909 1.379 13.508 3.313 16.797 5.799 3.287 2.49 4.933 7.156 4.933 13.998 0 6.844-2.2 11.864-6.6 15.063-4.4 3.2-10.82 4.8-19.262 4.8-5.512 0-23.901-2.04-23.901-2.04l.533-8.665c10.57 1.019 18.212 1.773 23.368 1.773 5.153 0 9.085-.821 11.797-2.466 2.71-1.644 4.066-4.4 4.066-8.265 0-3.866-1.156-6.487-3.465-7.865-2.313-1.377-7.38-2.688-15.198-3.933-7.821-1.243-13.377-3.066-16.663-5.466-3.29-2.4-4.933-6.842-4.933-13.331 0-6.486 2.287-11.285 6.865-14.397 4.577-3.11 10.286-4.666 17.13-4.666 5.42 0 24.23 1.379 24.23 1.379v8.717c-9.894-.452-18.01-1.164-23.696-1.164m73.949 1.066h-21.196v31.861c0 7.644.554 12.664 1.667 15.063 1.11 2.401 3.753 3.6 7.931 3.6l11.865-.8.667 8.265c-5.956.977-10.488 1.467-13.599 1.467-6.93 0-11.73-1.687-14.397-5.066-2.666-3.376-3.999-9.819-3.999-19.33v-35.06h-9.465v-8.665h9.465v-20.397h9.865v20.397h21.196v8.665zm13.9 58.808h9.999v-67.473h-9.999v67.473zm0-75.988h9.999v-11.598h-9.999v11.598zm53.304 7.182c2.935 0 7.91.534 14.932 1.6l3.198.4-.4 8.131c-7.11-.799-12.353-1.199-15.73-1.199-7.554 0-12.686 1.8-15.397 5.4-2.712 3.598-4.065 10.263-4.065 19.995 0 9.731 1.267 16.51 3.798 20.33 2.534 3.822 7.8 5.732 15.798 5.732l15.73-1.2.4 8.265c-8.264 1.243-14.442 1.866-18.53 1.866-10.399 0-17.576-2.666-21.529-7.998-3.955-5.332-5.932-14.33-5.932-26.995 0-12.664 2.132-21.55 6.399-26.662 4.265-5.109 11.375-7.665 21.328-7.665" fill="#221E1F"/>
<svg viewBox="0 0 325 325" xmlns="http://www.w3.org/2000/svg">
<path fill="#231F20" d="M0 0h325v325H0z"/>
<path d="M281.685 168.041c0 19.85-12.742 37.733-31.274 44.414a35.701 35.701 0 0 1 2.235 12.465c0 19.713-16.038 35.747-35.751 35.747-7.959 0-15.635-2.707-21.912-7.635-12.61 17.605-32.781 28.053-54.53 28.053-37.053 0-67.195-30.143-67.195-67.196 0-4.343.434-8.639 1.229-12.803-18.725-6.746-31.172-24.292-31.172-44.372 0-19.851 12.742-37.728 31.274-44.415a35.666 35.666 0 0 1-2.235-12.459c0-19.714 16.038-35.75 35.751-35.75a35.618 35.618 0 0 1 21.882 7.487c12.683-17.531 32.866-27.936 54.56-27.936 37.143 0 67.357 30.214 67.357 67.351 0 4.386-.427 8.597-1.246 12.81 18.64 6.795 31.027 24.261 31.027 44.239z" fill="#FEFEFE"/>
<path d="M137.031 145.902l52.159 23.779 52.625-46.11a58.246 58.246 0 0 0 1.134-11.565c0-32.443-26.39-58.839-58.833-58.839-19.408 0-37.511 9.557-48.515 25.58l-8.752 45.414 10.182 21.74v.001z" fill="#FED10C"/>
<path d="M83.04 201.136a59.861 59.861 0 0 0-1.152 11.742c0 32.526 26.467 58.992 58.998 58.992a58.803 58.803 0 0 0 48.745-25.834l8.688-45.26-11.594-22.155-52.365-23.867-51.32 46.382z" fill="#22B9AF"/>
<path d="M82.71 110.872l35.745 8.44 7.831-40.642a28.226 28.226 0 0 0-17.116-5.776c-15.534 0-28.167 12.64-28.167 28.173 0 3.431.573 6.722 1.707 9.805" fill="#EE5097"/>
<path d="M79.607 119.385c-15.97 5.292-27.074 20.602-27.074 37.44 0 16.396 10.14 31.038 25.36 36.832l50.151-45.331-9.207-19.674-39.23-9.267z" fill="#15A6DF"/>
<path d="M198.8 246.034c4.902 3.768 10.903 5.823 17.029 5.823 15.532 0 28.166-12.632 28.166-28.166 0-3.425-.573-6.715-1.707-9.798l-35.715-8.358-7.773 40.499z" fill="#91C63F"/>
<path d="M206.068 196.173l39.318 9.196c15.977-5.28 27.08-20.595 27.08-37.44 0-16.366-10.164-30.991-25.414-36.766l-51.426 45.052 10.442 19.958z" fill="#0979A0"/>
</svg>

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View file

@ -1,10 +0,0 @@
<svg viewBox="0 0 325 325" xmlns="http://www.w3.org/2000/svg">
<path fill="#231F20" d="M0 0h325v325H0z"/>
<path d="M281.685 168.041c0 19.85-12.742 37.733-31.274 44.414a35.701 35.701 0 0 1 2.235 12.465c0 19.713-16.038 35.747-35.751 35.747-7.959 0-15.635-2.707-21.912-7.635-12.61 17.605-32.781 28.053-54.53 28.053-37.053 0-67.195-30.143-67.195-67.196 0-4.343.434-8.639 1.229-12.803-18.725-6.746-31.172-24.292-31.172-44.372 0-19.851 12.742-37.728 31.274-44.415a35.666 35.666 0 0 1-2.235-12.459c0-19.714 16.038-35.75 35.751-35.75a35.618 35.618 0 0 1 21.882 7.487c12.683-17.531 32.866-27.936 54.56-27.936 37.143 0 67.357 30.214 67.357 67.351 0 4.386-.427 8.597-1.246 12.81 18.64 6.795 31.027 24.261 31.027 44.239z" fill="#FEFEFE"/>
<path d="M137.031 145.902l52.159 23.779 52.625-46.11a58.246 58.246 0 0 0 1.134-11.565c0-32.443-26.39-58.839-58.833-58.839-19.408 0-37.511 9.557-48.515 25.58l-8.752 45.414 10.182 21.74v.001z" fill="#FED10C"/>
<path d="M83.04 201.136a59.861 59.861 0 0 0-1.152 11.742c0 32.526 26.467 58.992 58.998 58.992a58.803 58.803 0 0 0 48.745-25.834l8.688-45.26-11.594-22.155-52.365-23.867-51.32 46.382z" fill="#22B9AF"/>
<path d="M82.71 110.872l35.745 8.44 7.831-40.642a28.226 28.226 0 0 0-17.116-5.776c-15.534 0-28.167 12.64-28.167 28.173 0 3.431.573 6.722 1.707 9.805" fill="#EE5097"/>
<path d="M79.607 119.385c-15.97 5.292-27.074 20.602-27.074 37.44 0 16.396 10.14 31.038 25.36 36.832l50.151-45.331-9.207-19.674-39.23-9.267z" fill="#15A6DF"/>
<path d="M198.8 246.034c4.902 3.768 10.903 5.823 17.029 5.823 15.532 0 28.166-12.632 28.166-28.166 0-3.425-.573-6.715-1.707-9.798l-35.715-8.358-7.773 40.499z" fill="#91C63F"/>
<path d="M206.068 196.173l39.318 9.196c15.977-5.28 27.08-20.595 27.08-37.44 0-16.366-10.164-30.991-25.414-36.766l-51.426 45.052 10.442 19.958z" fill="#0979A0"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.8 KiB

View file

@ -0,0 +1,17 @@
<svg viewBox="0 0 325 325" xmlns="http://www.w3.org/2000/svg">
<g>
<circle fill="#231F20" cx="162.5" cy="162.5" r="150"/>
<path d="M281.685 168.041c0 19.85-12.742 37.733-31.274 44.414a35.701 35.701 0 0 1 2.235 12.465c0 19.713-16.038 35.747-35.751 35.747-7.959 0-15.635-2.707-21.912-7.635-12.61 17.605-32.781 28.053-54.53 28.053-37.053 0-67.195-30.143-67.195-67.196 0-4.343.434-8.639 1.229-12.803-18.725-6.746-31.172-24.292-31.172-44.372 0-19.851 12.742-37.728 31.274-44.415a35.666 35.666 0 0 1-2.235-12.459c0-19.714 16.038-35.75 35.751-35.75a35.618 35.618 0 0 1 21.882 7.487c12.683-17.531 32.866-27.936 54.56-27.936 37.143 0 67.357 30.214 67.357 67.351 0 4.386-.427 8.597-1.246 12.81 18.64 6.795 31.027 24.261 31.027 44.239z" fill="#FEFEFE"/>
<path d="M137.031 145.902l52.159 23.779 52.625-46.11a58.246 58.246 0 0 0 1.134-11.565c0-32.443-26.39-58.839-58.833-58.839-19.408 0-37.511 9.557-48.515 25.58l-8.752 45.414 10.182 21.74v.001z" fill="#231F20"/>
<path d="M83.04 201.136a59.861 59.861 0 0 0-1.152 11.742c0 32.526 26.467 58.992 58.998 58.992a58.803 58.803 0 0 0 48.745-25.834l8.688-45.26-11.594-22.155-52.365-23.867-51.32 46.382z" fill="#231F20"/>
<path d="M82.71 110.872l35.745 8.44 7.831-40.642a28.226 28.226 0 0 0-17.116-5.776c-15.534 0-28.167 12.64-28.167 28.173 0 3.431.573 6.722 1.707 9.805" fill="#231F20"/>
<path d="M79.607 119.385c-15.97 5.292-27.074 20.602-27.074 37.44 0 16.396 10.14 31.038 25.36 36.832l50.151-45.331-9.207-19.674-39.23-9.267z" fill="#231F20"/>
<path d="M198.8 246.034c4.902 3.768 10.903 5.823 17.029 5.823 15.532 0 28.166-12.632 28.166-28.166 0-3.425-.573-6.715-1.707-9.798l-35.715-8.358-7.773 40.499z" fill="#231F20"/>
<path d="M206.068 196.173l39.318 9.196c15.977-5.28 27.08-20.595 27.08-37.44 0-16.366-10.164-30.991-25.414-36.766l-51.426 45.052 10.442 19.958z" fill="#231F20"/>
</g>
<g>
<path d="M302.68 312.88c-2.61 0-5.22-.996-7.212-2.987l-48.952-48.952c-3.985-3.985-3.985-10.439 0-14.42 3.982-3.986 10.444-3.986 14.42 0l48.953 48.952c3.985 3.985 3.985 10.439 0 14.42a10.152 10.152 0 0 1-7.208 2.986z" fill="#EE5097"/>
<path d="M244.764 244.766c-20.966 20.966-54.96 20.966-75.925 0-20.966-20.966-20.966-54.96 0-75.925 20.966-20.966 54.959-20.966 75.925 0 20.966 20.966 20.966 54.959 0 75.925z" fill-opacity=".7" fill="#15A6DF"/>
<path d="M206.803 156.116c12.97 0 25.946 4.95 35.842 14.846 19.796 19.796 19.796 51.886 0 71.683-9.896 9.895-22.871 14.846-35.842 14.846-12.97 0-25.946-4.95-35.841-14.846-19.797-19.797-19.797-51.887 0-71.683 9.895-9.896 22.87-14.846 35.841-14.846zm0-19.187c-18.664 0-36.21 7.267-49.407 20.467-27.245 27.246-27.245 71.573 0 98.819 13.196 13.196 30.743 20.468 49.407 20.468 18.664 0 36.211-7.267 49.407-20.468 27.246-27.246 27.246-71.573 0-98.819-13.196-13.2-30.743-20.467-49.407-20.467z" fill="#FED10C"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.8 KiB

View file

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View file

@ -1,6 +1,22 @@
<?php
call_user_func(function ($extension) {
call_user_func(function ($extension, $configuration) {
if (is_string($configuration)) {
$configuration = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf'][$extension]);
}
$iconRegistry = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Imaging\IconRegistry::class);
$iconRegistry->registerIcon(
'plugin-' . $extension . '-form',
\TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider::class,
['source' => 'EXT:search_core/Resources/Public/Icons/PluginForm.svg']
);
$iconRegistry->registerIcon(
'plugin-' . $extension . '-results',
\TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider::class,
['source' => 'EXT:search_core/Resources/Public/Icons/PluginResults.svg']
);
// TODO: Add hook for Extbase -> to handle records modified through
// Frontend and backend modules not using datahandler
\TYPO3\CMS\Core\Utility\ArrayUtility::mergeRecursiveWithOverrule(
@ -29,18 +45,27 @@ call_user_func(function ($extension) {
TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
'Codappix.' . $extension,
'search',
['Search' => 'search'],
['Search' => 'search']
'Results',
['Search' => 'results'],
['Search' => 'results']
);
TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
'Codappix.' . $extension,
'Form',
['Search' => 'form'],
['Search' => 'form']
);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(
'<INCLUDE_TYPOSCRIPT: source="FILE:EXT:' . $extension . '/Configuration/TSconfig/Page/Mod/Wizards/NewContentElement.tsconfig">'
);
\Codappix\SearchCore\Compatibility\ImplementationRegistrationService::registerImplementations();
// API does make use of object manager, therefore use GLOBALS
$extensionConfiguration = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf'][$extension]);
if ($extensionConfiguration === false
|| !isset($extensionConfiguration['disable.']['elasticsearch'])
|| $extensionConfiguration['disable.']['elasticsearch'] !== '1'
if (empty($configuration) ||
(isset($configuration['disable.']['elasticsearch']) &&
filter_var($configuration['disable.']['elasticsearch'], FILTER_VALIDATE_BOOLEAN) === false)
) {
\TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Extbase\Object\Container\Container::class)
->registerImplementation(
@ -48,4 +73,4 @@ call_user_func(function ($extension) {
\Codappix\SearchCore\Connection\Elasticsearch::class
);
}
}, $_EXTKEY);
}, $_EXTKEY, $_EXTCONF);