Bugzilla – Attachment 87141 Details for
Bug 18235
Elastic search - Configurable facets
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18235: (RM follow-up) fix mappings reset
Bug-18235-RM-follow-up-fix-mappings-reset.patch (text/plain), 1.45 KB, created by
Nick Clemens (kidclamp)
on 2019-03-28 15:45:30 UTC
(
hide
)
Description:
Bug 18235: (RM follow-up) fix mappings reset
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2019-03-28 15:45:30 UTC
Size:
1.45 KB
patch
obsolete
>From acae8133f60c5b8ef16c5fa1d7369cdce3801ac1 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Thu, 28 Mar 2019 15:12:52 +0000 >Subject: [PATCH] Bug 18235: (RM follow-up) fix mappings reset > >Without this we could not recreate mappings as there are no defaults for >the additional fields - this restores behavoiur from before patches >--- > Koha/SearchEngine/Elasticsearch.pm | 11 ++++++++--- > 1 file changed, 8 insertions(+), 3 deletions(-) > >diff --git a/Koha/SearchEngine/Elasticsearch.pm b/Koha/SearchEngine/Elasticsearch.pm >index 5f9370db20..81b1a8dea5 100644 >--- a/Koha/SearchEngine/Elasticsearch.pm >+++ b/Koha/SearchEngine/Elasticsearch.pm >@@ -285,11 +285,16 @@ sub reset_elasticsearch_mappings { > my $field_label = $data->{label}; > my $mappings = $data->{mappings}; > my $facet_order = $data->{facet_order}; >- my $search_field = Koha::SearchFields->find_or_create({ name => $field_name }); >+ my $search_field = Koha::SearchFields->find_or_create({ >+ name => $field_name, >+ label => $field_label, >+ type => $field_type, >+ }, >+ { >+ key => 'name' >+ }); > $search_field->update( > { >- label => $field_label, >- type => $field_type, > facet_order => $facet_order > } > ); >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18235
:
60931
|
60932
|
60933
|
61528
|
61529
|
61530
|
64747
|
69485
|
69486
|
69487
|
72936
|
72937
|
72938
|
72999
|
73000
|
73001
|
73193
|
74642
|
74643
|
75995
|
75996
|
85212
|
85213
|
85214
|
85215
|
85216
|
85885
|
85886
|
85969
|
85970
|
85983
|
85984
|
85985
|
85986
|
85987
|
85988
|
85989
|
85990
|
85991
|
85992
|
86340
|
86341
|
86342
|
86343
|
86344
|
86345
|
86346
|
86347
|
86348
|
86349
|
86350
|
86944
|
86945
|
86946
|
86947
|
86948
|
86949
|
86950
|
86951
|
86952
|
86953
|
86954
|
86955
|
86956
| 87141