From 70203a845e3df22348d537906b1375429b11e883 Mon Sep 17 00:00:00 2001
From: David Nind <david@davidnind.com>
Date: Sun, 8 Dec 2024 17:54:02 +0000
Subject: [PATCH] Bug 36609: Update index type labels for search engine
 configuration

This fixes the labels used for the type options when configuring
Elasticsearch search fields so that they use:
- sentence case
- the full name, instead of abbreviations (to make it clearer
  for translators)

Test plan:
1. Go to Administration > Catalog > Search engine
   configuration (Elasticsearch).
2. In the search fields tab, select the type column dropdown list
   for any field. Note the labels used for these options:
   - <empty entry> (the default option)
   - Std. Number
   - Call Number
3. Apply the patch.
4. Refresh the page.
5. Repeat step 2 and note that the option labels are now:
   - Default (instead of being blank)
   - Identfier (instead of Std. Number)
   - Call number (instead of Call Number)
6. Sign off D:

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
---
 .../admin/searchengine/elasticsearch/mappings.tt | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt
index b32a11b63f..7da6690526 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt
@@ -179,7 +179,7 @@ a.add, a.delete {
                                         [% ELSE %]
                                             <select name="search_field_type">
                                         [% END %]
-                                            <option value=""></option>
+                                            <option value="">Default</option>
                                             [% IF search_field.type == "string" %]
                                                 <option value="string" selected="selected">String</option>
                                             [% ELSE %]
@@ -216,14 +216,14 @@ a.add, a.delete {
                                                 <option value="isbn">ISBN</option>
                                             [% END %]
                                             [% IF search_field.type == "stdno" %]
-                                                <option value="stdno" selected="selected">Std. Number</option>
+                                                <option value="stdno" selected="selected">Identifier</option>
                                             [% ELSE %]
-                                                <option value="stdno">Std. Number</option>
+                                                <option value="stdno">Identifier</option>
                                             [% END %]
                                             [% IF search_field.type == "callnumber" %]
-                                                <option value="callnumber" selected="selected">Call Number</option>
+                                                <option value="callnumber" selected="selected">Call number</option>
                                             [% ELSE %]
-                                                <option value="callnumber">Call Number</option>
+                                                <option value="callnumber">Call number</option>
                                             [% END %]
                                             [% IF search_field.type == "geo_point" %]
                                               <option value="geo_point" selected="selected">Geo point</option>
@@ -282,7 +282,7 @@ a.add, a.delete {
                                 </td>
                                 <td>
                                     <select data-id="search_field_type">
-                                        <option value=""></option>
+                                        <option value="">Default</option>
                                         <option value="string">String</option>
                                         <option value="date">Date</option>
                                         <option value="year">Year</option>
@@ -290,8 +290,8 @@ a.add, a.delete {
                                         <option value="boolean">Boolean</option>
                                         <option value="sum">Sum</option>
                                         <option value="isbn">ISBN</option>
-                                        <option value="stdno">Std. Number</option>
-                                        <option value="callnumber">Call Number</option>
+                                        <option value="stdno">Identifierr</option>
+                                        <option value="callnumber">Call number</option>
                                         <option value="geo_point">Geo point</option>
                                     </select>
                                 </td>
-- 
2.39.5