From 23da9ccbd60f0bac3ef8da9f0c8c647d618c7b87 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Tue, 6 Jun 2023 15:18:02 +0000 Subject: [PATCH] Bug 33920: Improve translation of title tags: Patrons This patch updates patron module templates so that title tags can be more easily translated. To test, apply the patch and confirm that the following patron-related pages have the correct title tags: - Patrons home page - Patron search -> - Select two patrons -> Merge selected - Add patron -> - Add a patron with the same name and email address -> - Click "View existing record" in "Duplicate patron record?" dialog. - Patron details - Manage API keys (must have RESTOAuth2ClientCredentials enabled) - Accounting - Transactions - Print fee receipt - Print invoice - Make a payment - Create manual invoice - Create manual credit - Routing lists (must have RoutingSerials enabled) - Circulation history - Notices - Statistics - Files (must have EnableBorrowerFiles enabled) - Purchase suggestions - Discharges (must have useDischarge enabled) - Housebound (must have HouseboundModule enabled) - ILL requests history (must have ILLModule enabled) - Set permissions - Change password - Print summary - Print account balance - Two-factor authentication (must have TwoFactorAuthentication enabled) - Edit patron - Update child to adult patron: - Must have more than one "adult" type category defined - Locate a patron with a "child" type category - Choose More -> Update child to adult patron - Delete patron (confirmation page) - Pending discharge requests - Patrons requesting modifications --- .../prog/en/modules/members/accountline-details.tt | 12 +++++++++++- .../prog/en/modules/members/apikeys.tt | 7 ++++++- .../prog/en/modules/members/boraccount.tt | 7 ++++++- .../prog/en/modules/members/deletemem.tt | 7 ++++++- .../prog/en/modules/members/discharge.tt | 9 ++++++++- .../prog/en/modules/members/discharges.tt | 7 ++++++- .../intranet-tmpl/prog/en/modules/members/files.tt | 7 ++++++- .../prog/en/modules/members/holdshistory.tt | 7 ++++++- .../prog/en/modules/members/housebound.tt | 7 ++++++- .../prog/en/modules/members/ill-requests.tt | 7 ++++++- .../prog/en/modules/members/mancredit.tt | 9 ++++++--- .../prog/en/modules/members/maninvoice.tt | 9 ++++++--- .../prog/en/modules/members/member-flags.tt | 9 ++++++--- .../prog/en/modules/members/member-password.tt | 13 ++++++++++--- .../prog/en/modules/members/member.tt | 9 ++++++++- .../prog/en/modules/members/memberentrygen.tt | 14 ++++++++------ .../prog/en/modules/members/members-update.tt | 7 ++++++- .../prog/en/modules/members/merge-patrons.tt | 7 ++++++- .../prog/en/modules/members/moremember-brief.tt | 7 ++++++- .../prog/en/modules/members/moremember-print.tt | 12 ++++++++---- .../prog/en/modules/members/moremember.tt | 11 +++++++---- .../prog/en/modules/members/notices.tt | 7 ++++++- .../intranet-tmpl/prog/en/modules/members/pay.tt | 7 ++++++- .../prog/en/modules/members/paycollect.tt | 13 ++++++++----- .../prog/en/modules/members/printfeercpt.tt | 8 ++++++-- .../prog/en/modules/members/printinvoice.tt | 8 ++++++-- .../prog/en/modules/members/printnotice.tt | 8 ++++++-- .../en/modules/members/purchase-suggestions.tt | 7 ++++++- .../prog/en/modules/members/readingrec.tt | 7 ++++++- .../prog/en/modules/members/recallshistory.tt | 7 ++++++- .../prog/en/modules/members/routing-lists.tt | 7 ++++++- .../prog/en/modules/members/search.tt | 7 ++++++- .../prog/en/modules/members/statistics.tt | 11 +++++++---- .../prog/en/modules/members/two_factor_auth.tt | 7 ++++++- .../prog/en/modules/members/update-child.tt | 7 ++++++- 35 files changed, 231 insertions(+), 64 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/accountline-details.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/accountline-details.tt index 36cbf604c8..894e712799 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/accountline-details.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/accountline-details.tt @@ -4,10 +4,20 @@ [%- USE KohaDates -%] [%- USE AuthorisedValues -%] [%- USE Branches -%] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% PROCESS 'accounts.inc' %] [% INCLUDE 'doc-head-open.inc' %] -Details of [% IF type == 'credit' %]credit[% ELSE %]debit[% END %] › [% INCLUDE 'patron-title.inc' no_html = 1 %] › Patrons › Koha +[% FILTER collapse %] + [% IF type == 'credit' %] + [% t("Details of credit") | html %] + [% ELSE %] + [% t("Details of debit") | html %] + [% END %] › + [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/apikeys.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/apikeys.tt index 6f86af08f7..1471572aa2 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/apikeys.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/apikeys.tt @@ -1,9 +1,14 @@ [% USE raw %] [% USE Koha %] [% USE Asset %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -API Keys › Patrons › Koha +[% FILTER collapse %] + [% t("API Keys") | html %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt index 1651563215..d28fbdfdad 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt @@ -8,13 +8,18 @@ [% USE Price %] [% USE Branches %] [% USE Registers %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% SET registers = Registers.all( filters => { current_branch => 1 } ) %] [% PROCESS 'accounts.inc' %] [% INCLUDE 'doc-head-open.inc' %] -Account for [% INCLUDE 'patron-title.inc' no_html = 1 %] › Patrons › Koha +[% FILTER collapse %] + [% t("Account for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/deletemem.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/deletemem.tt index 4ac2f80c4e..db5ab43261 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/deletemem.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/deletemem.tt @@ -2,9 +2,14 @@ [% USE Asset %] [% USE Price %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Delete patron [% patron.firstname | html %] [% patron.surname | html %] › Koha +[% FILTER collapse %] + [% t("Delete patron") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharge.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharge.tt index b8d1e62535..9ca6de3099 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharge.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharge.tt @@ -3,9 +3,16 @@ [% USE KohaDates %] [% USE AuthorisedValues %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -[% UNLESS blocking_error %]Discharge for [% patron.firstname | html %] [% patron.surname | html %] ([% patron.cardnumber | html %])[% END %] › Patrons › Koha +[% FILTER collapse %] + [% UNLESS blocking_error %] + [% t("Discharge for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% END %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharges.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharges.tt index 9559c58359..f9190e3e0d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharges.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/discharges.tt @@ -2,9 +2,14 @@ [% USE Asset %] [% USE Branches %] [% USE KohaDates %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Pending discharge requests › Patrons › Koha +[% FILTER collapse %] + [% t("Pending discharge requests") | html %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt index bda394864b..51e923f25e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt @@ -3,9 +3,14 @@ [% USE KohaDates %] [% USE Branches %] [% USE AuthorisedValues %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Files for [% INCLUDE 'patron-title.inc' no_html = 1 %] +[% FILTER collapse %] + [% t("Files for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt index a2e82c8775..ea423c6935 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt @@ -6,9 +6,14 @@ [% USE Branches %] [% USE TablesSettings %] [% USE ItemTypes %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Holds history for [% INCLUDE 'patron-title.inc' no_html = 1 %] +[% FILTER collapse %] + [% t("Holds history for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt index f65655b0a7..ebc4dc6924 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt @@ -4,9 +4,14 @@ [% USE KohaDates %] [% USE AuthorisedValues %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Details for [% INCLUDE 'patron-title.inc' no_html = 1 %] › Housebound › Koha +[% FILTER collapse %] + [% t("Details for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% t("Housebound") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/ill-requests.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/ill-requests.tt index 4b7c30fb9e..cea915d595 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/ill-requests.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/ill-requests.tt @@ -3,12 +3,17 @@ [% USE Branches %] [% USE Koha %] [% USE KohaDates %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% USE AuthorisedValues %] [% USE TablesSettings %] [% INCLUDE 'doc-head-open.inc' %] -ILL requests history for [% INCLUDE 'patron-title.inc' no_html = 1 %] › Patrons › Koha +[% FILTER collapse %] + [% t("ILL requests history for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/mancredit.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/mancredit.tt index 74395fff92..7493987d21 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/mancredit.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/mancredit.tt @@ -3,13 +3,16 @@ [% USE Koha %] [% USE Branches %] [% USE Registers %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] - [% PROCESS 'accounts.inc' %] - [% INCLUDE 'doc-head-open.inc' %] [% SET registers = Registers.all( { filters => { current_branch => 1 } } ) %] -Create manual credit › Patrons › Koha +[% FILTER collapse %] + [% t("Create manual credit") | html %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt index 3eeb822c53..8113199b46 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt @@ -3,12 +3,15 @@ [% USE Koha %] [% USE Price %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] - [% PROCESS 'accounts.inc' %] - [% INCLUDE 'doc-head-open.inc' %] -Create manual invoice › Patrons › Koha +[% FILTER collapse %] + [% t("Create manual invoice") | html %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt index 7e475132bb..e7deafe761 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt @@ -1,12 +1,15 @@ [% USE raw %] [% USE Asset %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% PROCESS 'permissions.inc' %] [% INCLUDE 'doc-head-open.inc' %] - - Set permissions for [% INCLUDE 'patron-title.inc' no_html = 1 %] › Patrons › Koha - +[% FILTER collapse %] + [% t("Set permissions for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt index 261611a1d8..006d073f97 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-password.tt @@ -2,11 +2,18 @@ [% USE Asset %] [% USE Koha %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] - - [% IF ( newpassword ) %]Password updated [% ELSE %]Update password for [% patron.surname | html %], [% patron.firstname | html %][% END %] › Patrons › Koha - +[% FILTER collapse %] + [% IF ( newpassword ) %] + [% t("Password updated") | html %] + [% ELSE %] + [% t("Update password for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] › + [% END %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt index 1966c6e8a9..7fb083cf9c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt @@ -4,6 +4,7 @@ [% USE TablesSettings %] [% USE Branches %] [% USE Categories %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% PROCESS 'patronfields.inc' %] [% SET libraries = Branches.all %] @@ -11,7 +12,13 @@ [% SET columns = ['cardnumber', 'name-address', 'dateofbirth', 'branch', 'category', 'dateexpiry', 'checkouts', 'account_balance', 'borrowernotes', 'action'] %] [% PROCESS 'patron-search.inc' %] [% INCLUDE 'doc-head-open.inc' %] -Patrons[% IF ( searching ) %] › Search results[% END %] › Koha +[% FILTER collapse %] + [% IF ( searching ) %] + [% t("Search results") | html %] › + [% END %] + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt index 6859a24478..5fa0211b08 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt @@ -1,4 +1,3 @@ -[% PROCESS 'i18n.inc' %] [% USE raw %] [% USE Asset %] [% USE To %] @@ -9,19 +8,22 @@ [% PROCESS 'member-alt-address-style.inc' %] [% PROCESS 'member-alt-contact-style.inc' %] [% PROCESS 'restriction-types.inc' %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] - +<title>[% FILTER collapse %] [% UNLESS blocking_error %] [% IF ( opadd ) %] - Add patron + [% t("Add patron") | html %] [% ELSE %] - Modify patron + [% t("Modify patron") | html %] [% END %] [% INCLUDE 'patron-title.inc' no_html = 1 %] [% IF patron_category %]([% patron_category.description | html %])[% END %] - [% END %] › Patrons › Koha - + [% END %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [%# FIXME This is not great, we should make members/memberentrygen.tt use a modal as well and we won't need that here %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt index 1ea5ca9ef0..e3cf8a53ec 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt @@ -3,13 +3,16 @@ [% USE Koha %] [% USE AuthorisedValues %] [% USE Branches %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] - +<title>[% FILTER collapse %] [% UNLESS blocking_error %] - Statistics for [% INCLUDE 'patron-title.inc' no_html = 1 %] - [% END %] › Patrons › Koha - + [% t("Statistics for") | html %] [% INCLUDE 'patron-title.inc' no_html = 1 %] + [% END %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/two_factor_auth.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/two_factor_auth.tt index 9d34b9b8f1..4d08a92581 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/two_factor_auth.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/two_factor_auth.tt @@ -1,9 +1,14 @@ [% USE raw %] [% USE Koha %] [% USE Asset %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Two-factor authentication › Patrons › Koha +[% FILTER collapse %] + [% t("Two-factor authentication") | html %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/update-child.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/update-child.tt index 460ee2d190..1acdf6546a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/update-child.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/update-child.tt @@ -1,8 +1,13 @@ [% USE raw %] [% USE Asset %] +[% PROCESS 'i18n.inc' %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Choose adult category › Koha +[% FILTER collapse %] + [% t("Choose adult category") | html %] › + [% t("Patrons") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] -- 2.30.2