Bugzilla – Attachment 161338 Details for
Bug 35097
Use country-list.inc to display choices for UsageStatsCountry preference
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35097: Use country-list.inc to display choices for UsageStatsCountry preference
Bug-35097-Use-country-listinc-to-display-choices-f.patch (text/plain), 11.89 KB, created by
Martin Renvoize (ashimema)
on 2024-01-24 14:35:51 UTC
(
hide
)
Description:
Bug 35097: Use country-list.inc to display choices for UsageStatsCountry preference
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2024-01-24 14:35:51 UTC
Size:
11.89 KB
patch
obsolete
>From ce4cf75ab833062fab46fbaa693a8d391472227f Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Wed, 18 Oct 2023 16:00:45 +0000 >Subject: [PATCH] Bug 35097: Use country-list.inc to display choices for > UsageStatsCountry preference > >This patch updates the system preferences interface so that it uses >country-list.inc for the selection of countries for the >UsageStatsCountry preference. > >To test, apply the patch and restart services. > >- Go to Administration -> System preferences and search for > "UsageStatsCountry" >- The dropdown of countries should look correct. >- Select a country, save, and confirm that your choice is saved > correctly. > >Signed-off-by: David Nind <david@davidnind.com> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > .../prog/en/modules/admin/preferences.tt | 12 ++ > .../en/modules/admin/preferences/admin.pref | 198 +----------------- > 2 files changed, 13 insertions(+), 197 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences.tt >index deaaadb9826..3a42e208f69 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences.tt >@@ -195,6 +195,18 @@ > [% END # IF language.plural %] > [% END # FOREACH language %] > </ul> <!-- / ul.sortable --> >+ [% ELSIF ( CHUNK.type_countries ) %] >+ [% PROCESS 'country-list.inc' %] >+ <select name="pref_[% CHUNK.name | html %]" id="pref_[% CHUNK.name | html %]" class="preference preference-[% CHUNK.class or "choice" | html %]"> >+ <option value=""> </option> >+ [% FOREACH country IN country_strings.split(',') %] >+ [% IF country.trim == CHUNK.value %] >+ <option value="[% country.trim | html %]" selected="selected">[% country.trim | html %]</option> >+ [% ELSE %] >+ <option value="[% country.trim | html %]">[% country.trim | html %]</option> >+ [% END %] >+ [% END %] >+ </select> > [% END %] > [% END %] > [% IF LINE.WARNINGS.size %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref >index 84238d0e53f..f1522c8caa0 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref >@@ -236,203 +236,7 @@ Administration: > - > - "The country where your library is located to be shown on the Hea Community website: " > - pref: UsageStatsCountry >- default: "" >- choices: >- "" : "" >- Afghanistan : "Afghanistan" >- Albania : "Albania" >- Algeria : "Algeria" >- Andorra : "Andorra" >- Angola : "Angola" >- Antigua & Deps : "Antigua & Deps" >- Argentina : "Argentina" >- Armenia : "Armenia" >- Australia : "Australia" >- Austria : "Austria" >- Azerbaijan : "Azerbaijan" >- Bahamas : "Bahamas" >- Bahrain : "Bahrain" >- Bangladesh : "Bangladesh" >- Barbados : "Barbados" >- Belarus : "Belarus" >- Belgium : "Belgium" >- Belize : "Belize" >- Benin : "Benin" >- Bhutan : "Bhutan" >- Bolivia : "Bolivia" >- Bosnia Herz. : "Bosnia Herz." >- Botswana : "Botswana" >- Brazil : "Brazil" >- Brunei : "Brunei" >- Bulgaria : "Bulgaria" >- Burkina : "Burkina" >- Burundi : "Burundi" >- Cambodia : "Cambodia" >- Cameroon : "Cameroon" >- Canada : "Canada" >- Cape Verde : "Cape Verde" >- Centr. Afr. Rep: "Centr. Afr. Rep" >- Chad : "Chad" >- Chile : "Chile" >- China : "China" >- Colombia : "Colombia" >- Comoros : "Comoros" >- Congo : "Congo" >- Costa Rica : "Costa Rica" >- Croatia : "Croatia" >- Cuba : "Cuba" >- Cyprus : "Cyprus" >- Czech Republic : "Czech Republic" >- Denmark : "Denmark" >- Djibouti : "Djibouti" >- Dominica : "Dominica" >- Dominican Rep. : "Dominican Rep." >- East Timor : "East Timor" >- Ecuador : "Ecuador" >- Egypt : "Egypt" >- El Salvador : "El Salvador" >- Equator. Guinea: "Equator. Guinea" >- Eritrea : "Eritrea" >- Estonia : "Estonia" >- Ethiopia : "Ethiopia" >- Fiji : "Fiji" >- Finland : "Finland" >- France : "France" >- Gabon : "Gabon" >- Gambia : "Gambia" >- Georgia : "Georgia" >- Germany : "Germany" >- Ghana : "Ghana" >- Greece : "Greece" >- Grenada : "Grenada" >- Guatemala : "Guatemala" >- Guinea : "Guinea" >- Guinea-Bissau : "Guinea-Bissau" >- Guyana : "Guyana" >- Haiti : "Haiti" >- Honduras : "Honduras" >- Hungary : "Hungary" >- Iceland : "Iceland" >- India : "India" >- Indonesia : "Indonesia" >- Iran : "Iran" >- Iraq : "Iraq" >- Ireland : "Ireland" >- Israel : "Israel" >- Italy : "Italy" >- Ivory Coast : "Ivory Coast" >- Jamaica : "Jamaica" >- Japan : "Japan" >- Jordan : "Jordan" >- Kazakhstan : "Kazakhstan" >- Kenya : "Kenya" >- Kiribati : "Kiribati" >- Korea North : "Korea North" >- Korea South : "Korea South" >- Kosovo : "Kosovo" >- Kuwait : "Kuwait" >- Kyrgyzstan : "Kyrgyzstan" >- Laos : "Laos" >- Latvia : "Latvia" >- Lebanon : "Lebanon" >- Lesotho : "Lesotho" >- Liberia : "Liberia" >- Libya : "Libya" >- Liechtenstein : "Liechtenstein" >- Lithuania : "Lithuania" >- Luxembourg : "Luxembourg" >- Macedonia : "Macedonia" >- Madagascar : "Madagascar" >- Malawi : "Malawi" >- Malaysia : "Malaysia" >- Maldives : "Maldives" >- Mali : "Mali" >- Malta : "Malta" >- Marshall Isl. : "Marshall Isl." >- Mauritania : "Mauritania" >- Mauritius : "Mauritius" >- Mexico : "Mexico" >- Micronesia : "Micronesia" >- Moldova : "Moldova" >- Monaco : "Monaco" >- Mongolia : "Mongolia" >- Montenegro : "Montenegro" >- Morocco : "Morocco" >- Mozambique : "Mozambique" >- Myanmar : "Myanmar" >- Namibia : "Namibia" >- Nauru : "Nauru" >- Nepal : "Nepal" >- Netherlands : "Netherlands" >- New Zealand : "New Zealand" >- Nicaragua : "Nicaragua" >- Niger : "Niger" >- Nigeria : "Nigeria" >- Norway : "Norway" >- Oman : "Oman" >- Pakistan : "Pakistan" >- Palau : "Palau" >- Panama : "Panama" >- Papua N. Guinea: "Papua N. Guinea" >- Paraguay : "Paraguay" >- Peru : "Peru" >- Philippines : "Philippines" >- Poland : "Poland" >- Portugal : "Portugal" >- Qatar : "Qatar" >- Romania : "Romania" >- Russian Fed. : "Russian Fed." >- Rwanda : "Rwanda" >- St Kitts & Nev.: "St Kitts & Nev." >- St Lucia : "St Lucia" >- St Vincent : "Saint Vincent" >- Samoa : "Samoa" >- San Marino : "San Marino" >- Sao Tome : "Sao Tome" >- Saudi Arabia : "Saudi Arabia" >- Senegal : "Senegal" >- Serbia : "Serbia" >- Seychelles : "Seychelles" >- Sierra Leone : "Sierra Leone" >- Singapore : "Singapore" >- Slovakia : "Slovakia" >- Slovenia : "Slovenia" >- Solomon Islands: "Solomon Islands" >- Somalia : "Somalia" >- South Africa : "South Africa" >- Spain : "Spain" >- Sri Lanka : "Sri Lanka" >- Sudan : "Sudan" >- Suriname : "Suriname" >- Swaziland : "Swaziland" >- Sweden : "Sweden" >- Switzerland : "Switzerland" >- Syria : "Syria" >- Taiwan : "Taiwan" >- Tajikistan : "Tajikistan" >- Tanzania : "Tanzania" >- Thailand : "Thailand" >- Togo : "Togo" >- Tonga : "Tonga" >- Trinidad & Tob.: "Trinidad & Tob." >- Tunisia : "Tunisia" >- Turkey : "Turkey" >- Turkmenistan : "Turkmenistan" >- Tuvalu : "Tuvalu" >- Uganda : "Uganda" >- Ukraine : "Ukraine" >- UAE : "UAE" >- United Kingdom : "United Kingdom" >- USA : "USA" >- Uruguay : "Uruguay" >- Uzbekistan : "Uzbekistan" >- Vanuatu : "Vanuatu" >- Vatican City : "Vatican City" >- Venezuela : "Venezuela" >- Vietnam : "Vietnam" >- Yemen : "Yemen" >- Zambia : "Zambia" >- Zimbabwe : "Zimbabwe" >+ type: countries > > - . This will be shown on the <a href="https://hea.koha-community.org">Hea Koha community website</a>. > - <br><strong>NOTE:</strong> This value has no effect if the <a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=UsageStats">UsageStats</a> system preference is set to "No" (don't share). >-- >2.43.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 35097
:
157340
|
157429
| 161338