Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
services
t3o sites
extensions.typo3.org
extensions.typo3.org
Commits
8622e5e3
Commit
8622e5e3
authored
Mar 21, 2017
by
Thomas Löffler
Browse files
[TASK] Adds queryFields and indexes the whole dependency string
parent
4548c1d8
Pipeline
#185
passed with stages
in 1 minute and 49 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
html/typo3conf/ext/ter_fe2/Classes/Solr/Indexqueue/TerIndexer.php
View file @
8622e5e3
...
@@ -15,6 +15,7 @@
...
@@ -15,6 +15,7 @@
use
TYPO3\CMS\Core\Utility\GeneralUtility
;
use
TYPO3\CMS\Core\Utility\GeneralUtility
;
use
ApacheSolrForTypo3\Solr\IndexQueue\Item
;
use
ApacheSolrForTypo3\Solr\IndexQueue\Item
;
use
TYPO3\CMS\Core\Utility\VersionNumberUtility
;
/**
/**
* Class Tx_TerFe2_Solr_Indexqueue_TerIndexer
* Class Tx_TerFe2_Solr_Indexqueue_TerIndexer
...
@@ -93,6 +94,11 @@ class Tx_TerFe2_Solr_Indexqueue_TerIndexer extends \ApacheSolrForTypo3\Solr\Inde
...
@@ -93,6 +94,11 @@ class Tx_TerFe2_Solr_Indexqueue_TerIndexer extends \ApacheSolrForTypo3\Solr\Inde
$document
->
setField
(
'extensionMinTYPO3Version_tIntS'
,
$typo3Dependency
[
'minimum'
]);
$document
->
setField
(
'extensionMinTYPO3Version_tIntS'
,
$typo3Dependency
[
'minimum'
]);
$document
->
setField
(
'extensionMaxTYPO3Version_tIntS'
,
$typo3Dependency
[
'maximum'
]);
$document
->
setField
(
'extensionMaxTYPO3Version_tIntS'
,
$typo3Dependency
[
'maximum'
]);
$dependencyString
=
''
;
$dependencyString
.
=
$typo3Dependency
[
'minimum'
]
>
0
?
VersionNumberUtility
::
convertIntegerToVersionNumber
(
$typo3Dependency
[
'minimum'
])
:
''
;
$dependencyString
.
=
$typo3Dependency
[
'maximum'
]
>
0
?
' - '
.
VersionNumberUtility
::
convertIntegerToVersionNumber
(
$typo3Dependency
[
'maximum'
])
:
''
;
$document
->
setField
(
'extensionDependency_stringS'
,
$dependencyString
?:
'N/A'
);
$document
->
setField
(
'outdated_boolS'
,
$extension
->
getLastVersion
()
->
getReviewState
()
===
-
2
);
$document
->
setField
(
'outdated_boolS'
,
$extension
->
getLastVersion
()
->
getReviewState
()
===
-
2
);
}
}
...
@@ -175,4 +181,4 @@ class Tx_TerFe2_Solr_Indexqueue_TerIndexer extends \ApacheSolrForTypo3\Solr\Inde
...
@@ -175,4 +181,4 @@ class Tx_TerFe2_Solr_Indexqueue_TerIndexer extends \ApacheSolrForTypo3\Solr\Inde
$fileType
=
strtolower
(
trim
(
$fileType
,
'. '
));
$fileType
=
strtolower
(
trim
(
$fileType
,
'. '
));
return
$extension
[
0
]
.
'/'
.
$extension
[
1
]
.
'/'
.
$extension
.
'_'
.
$version
.
'.'
.
$fileType
;
return
$extension
[
0
]
.
'/'
.
$extension
[
1
]
.
'/'
.
$extension
.
'_'
.
$version
.
'.'
.
$fileType
;
}
}
}
}
\ No newline at end of file
html/typo3conf/ext/ter_fe2/Configuration/TypoScript/Default/Plugins/Solr.ts
View file @
8622e5e3
...
@@ -141,12 +141,6 @@ plugin {
...
@@ -141,12 +141,6 @@ plugin {
extensionDownloads_intS
=
downloads
extensionDownloads_intS
=
downloads
extensionHasZipFile_intS
=
SOLR_RELATION
extensionHasZipFile_intS
{
localField
=
last_version
foreignLabelField
=
has_zip_file
}
extensionManual_intS
=
SOLR_RELATION
extensionManual_intS
=
SOLR_RELATION
extensionManual_intS
{
extensionManual_intS
{
localField
=
last_version
localField
=
last_version
...
@@ -213,12 +207,11 @@ plugin {
...
@@ -213,12 +207,11 @@ plugin {
}
}
}
}
}
}
search
{
search
{
query
{
query
{
// qf parameter http://wiki.apache.org/solr/DisMaxQParserPlugin#qf_.28Query_Fields.29
// qf parameter http://wiki.apache.org/solr/DisMaxQParserPlugin#qf_.28Query_Fields.29
queryFields
=
content
^
40.0
,
extensionKey_textS
^
20.0
,
title
^
5.0
,
keywords
^
2.0
,
tagsH1
^
5.0
,
tagsH2H3
^
3.0
,
tagsH4H5H6
^
2.0
,
tagsInline
^
1.0
,
author
^
1.0
queryFields
=
extensionKey_stringS
^
60.0
,
keywords
^
55.0
,
title
^
50.0
,
content
^
40.0
,
author
^
1.0
}
}
}
}
}
}
}
}
}
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment