Closed joomlapl-bot closed 7 months ago
PR w związku ze zmianą oryginału https://github.com/joomla/joomla-cms/pull/36867 Poniżej zmiany w oryginale:
PR w związku ze zmianą oryginału https://github.com/joomla/joomla-cms/pull/36867 Poniżej zmiany w oryginale:
Click to expand the diff!
```diff diff --git a/administrator/components/com_finder/src/Field/TaxonomytypesField.php b/administrator/components/com_finder/src/Field/TaxonomytypesField.php new file mode 100644 index 000000000000..f8f763f22726 --- /dev/null +++ b/administrator/components/com_finder/src/Field/TaxonomytypesField.php @@ -0,0 +1,50 @@ + + * @license GNU General Public License version 2 or later; see LICENSE.txt + */ + +namespace Joomla\Component\Finder\Administrator\Field; + +use Joomla\CMS\Form\Field\CheckboxesField; + +/** + * Taxonomy Types field for the Finder package. + * This is a helper to allow to save an empty set of + * options by having a hidden field with a "none" value. + * + * @since __DEPLOY_VERSION__ + */ +class TaxonomytypesField extends CheckboxesField +{ + /** + * The form field type. + * + * @var string + * @since __DEPLOY_VERSION__ + */ + protected $type = 'TaxonomyTypes'; + + /** + * Method to get the field input markup for a generic list. + * Use the multiple attribute to enable multiselect. + * + * @return string The field input markup. + * + * @since __DEPLOY_VERSION__ + */ + protected function getInput() + { + $html = parent::getInput(); + + $data = $this->getLayoutData(); + $data['id'] .= '_hidden'; + $data['value'] = 'none'; + + return $html . $this->getRenderer('joomla.form.field.hidden')->render($data); + } +} diff --git a/administrator/language/en-GB/plg_finder_categories.ini b/administrator/language/en-GB/plg_finder_categories.ini index d97f8c763fe8..62e086af6adf 100644 --- a/administrator/language/en-GB/plg_finder_categories.ini +++ b/administrator/language/en-GB/plg_finder_categories.ini @@ -5,3 +5,6 @@ PLG_FINDER_CATEGORIES="Smart Search - Categories" PLG_FINDER_CATEGORIES_XML_DESCRIPTION="This plugin indexes Joomla! Categories." +PLG_FINDER_CATEGORIES_TAXONOMIES_LABEL="Taxonomies to Index" +PLG_FINDER_CATEGORIES_TAXONOMIES_LANGUAGE="Language" +PLG_FINDER_CATEGORIES_TAXONOMIES_TYPE="Type" diff --git a/administrator/language/en-GB/plg_finder_contacts.ini b/administrator/language/en-GB/plg_finder_contacts.ini index f7ca24805624..d55214f36b51 100644 --- a/administrator/language/en-GB/plg_finder_contacts.ini +++ b/administrator/language/en-GB/plg_finder_contacts.ini @@ -5,6 +5,12 @@ PLG_FINDER_CONTACTS="Smart Search - Contacts" PLG_FINDER_CONTACTS_XML_DESCRIPTION="This plugin indexes Joomla! Contacts." +PLG_FINDER_CONTACTS_TAXONOMIES_CATEGORY="Category" +PLG_FINDER_CONTACTS_TAXONOMIES_COUNTRY="Country" +PLG_FINDER_CONTACTS_TAXONOMIES_LABEL="Taxonomies to Index" +PLG_FINDER_CONTACTS_TAXONOMIES_LANGUAGE="Language" +PLG_FINDER_CONTACTS_TAXONOMIES_REGION="Region" +PLG_FINDER_CONTACTS_TAXONOMIES_TYPE="Type" PLG_FINDER_QUERY_FILTER_BRANCH_P_CONTACT="Contacts" PLG_FINDER_QUERY_FILTER_BRANCH_P_COUNTRY="Countries" PLG_FINDER_QUERY_FILTER_BRANCH_P_REGION="Regions" diff --git a/administrator/language/en-GB/plg_finder_content.ini b/administrator/language/en-GB/plg_finder_content.ini index 8666746f3b9a..4a58a44c7c39 100644 --- a/administrator/language/en-GB/plg_finder_content.ini +++ b/administrator/language/en-GB/plg_finder_content.ini @@ -4,6 +4,11 @@ ; Note : All ini files need to be saved as UTF-8 PLG_FINDER_CONTENT="Smart Search - Content" +PLG_FINDER_CONTENT_TAXONOMIES_AUTHOR="Author" +PLG_FINDER_CONTENT_TAXONOMIES_CATEGORY="Category" +PLG_FINDER_CONTENT_TAXONOMIES_LABEL="Taxonomies to Index" +PLG_FINDER_CONTENT_TAXONOMIES_LANGUAGE="Language" +PLG_FINDER_CONTENT_TAXONOMIES_TYPE="Type" PLG_FINDER_CONTENT_XML_DESCRIPTION="Updates the indexes of Joomla! Articles whenever an article is created, modified or deleted. NOTE the Content - Smart Search plugin must be enabled." PLG_FINDER_QUERY_FILTER_BRANCH_P_ARTICLE="Articles" PLG_FINDER_QUERY_FILTER_BRANCH_P_AUTHOR="Authors" diff --git a/administrator/language/en-GB/plg_finder_newsfeeds.ini b/administrator/language/en-GB/plg_finder_newsfeeds.ini index c3a6c37ade57..e311469ada5a 100644 --- a/administrator/language/en-GB/plg_finder_newsfeeds.ini +++ b/administrator/language/en-GB/plg_finder_newsfeeds.ini @@ -5,5 +5,9 @@ PLG_FINDER_NEWSFEEDS="Smart Search - News Feeds" PLG_FINDER_NEWSFEEDS_XML_DESCRIPTION="This plugin indexes Joomla! News feeds." +PLG_FINDER_NEWSFEEDS_TAXONOMIES_CATEGORY="Category" +PLG_FINDER_NEWSFEEDS_TAXONOMIES_LABEL="Taxonomies to Index" +PLG_FINDER_NEWSFEEDS_TAXONOMIES_LANGUAGE="Language" +PLG_FINDER_NEWSFEEDS_TAXONOMIES_TYPE="Type" PLG_FINDER_QUERY_FILTER_BRANCH_P_NEWS_FEED="News feeds" PLG_FINDER_QUERY_FILTER_BRANCH_S_NEWS_FEED="News feed" diff --git a/administrator/language/en-GB/plg_finder_tags.ini b/administrator/language/en-GB/plg_finder_tags.ini index 9ddbd0c01124..14b009a250aa 100644 --- a/administrator/language/en-GB/plg_finder_tags.ini +++ b/administrator/language/en-GB/plg_finder_tags.ini @@ -7,3 +7,7 @@ PLG_FINDER_QUERY_FILTER_BRANCH_P_TAG="Tags" PLG_FINDER_QUERY_FILTER_BRANCH_S_TAG="Tag" PLG_FINDER_TAGS="Smart Search - Tags" PLG_FINDER_TAGS_XML_DESCRIPTION="This plugin indexes Joomla! Tags." +PLG_FINDER_TAGS_TAXONOMIES_AUTHOR="Author" +PLG_FINDER_TAGS_TAXONOMIES_LABEL="Taxonomies to Index" +PLG_FINDER_TAGS_TAXONOMIES_LANGUAGE="Language" +PLG_FINDER_TAGS_TAXONOMIES_TYPE="Type" diff --git a/plugins/finder/categories/categories.xml b/plugins/finder/categories/categories.xml index 337b2dd77d13..20838b34bdb3 100644 --- a/plugins/finder/categories/categories.xml +++ b/plugins/finder/categories/categories.xml @@ -18,4 +18,20 @@