mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-04-04 10:29:34 +00:00
Solr doesn't define a ukrainian text field by default
This commit is contained in:
parent
aad73824d7
commit
df98a4c069
@ -164,10 +164,15 @@ object SolrSetup {
|
||||
),
|
||||
SolrMigration[F](
|
||||
29,
|
||||
"Add new field type for ukrainian content",
|
||||
addFieldType(AddFieldType.textUkr)
|
||||
),
|
||||
SolrMigration[F](
|
||||
30,
|
||||
"Add Ukrainian",
|
||||
addContentField(Language.Ukrainian)
|
||||
),
|
||||
SolrMigration.reIndexAll(30, "Re-Index after adding Estonian and Ukrainian")
|
||||
SolrMigration.reIndexAll(31, "Re-Index after adding Estonian and Ukrainian")
|
||||
)
|
||||
|
||||
def addFolderField: F[Unit] =
|
||||
@ -331,6 +336,17 @@ object SolrSetup {
|
||||
)
|
||||
)
|
||||
|
||||
val textUkr = AddFieldType(
|
||||
"text_uk",
|
||||
"solr.TextField",
|
||||
Analyzer(
|
||||
Tokenizer("solr.StandardTokenizerFactory", Map.empty),
|
||||
List(
|
||||
Filter("solr.LowerCaseFilterFactory", Map.empty)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
final case class Filter(`class`: String, attr: Map[String, String])
|
||||
final case class Tokenizer(`class`: String, attr: Map[String, String])
|
||||
final case class Analyzer(tokenizer: Tokenizer, filter: List[Filter])
|
||||
|
Loading…
x
Reference in New Issue
Block a user