Koha/koha-tmpl/intranet-tmpl/prog/en/modules/clubs/club-enrollments.tt
Owen Leonard 3f6b956533
Bug 33919: Improve translation of title tags: Patron clubs
This patch updates patron clubs templates so that title tags can be more
easily translated.

The patch also makes some minor changes to some templates to improve
consistency between page title, breadcrumb navigation, and page heading.

To test, apply the patch and confirm that the following pages have the
correct title tags:

- Tools -> Patron clubs
  - New and Edit club template
  - New and Edit club
  - Club enrollments (from the list of clubs choose Actions ->
    Enrollments)

Signed-off-by: Salah Ghedda <salah.ghedda@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-22 10:52:49 -03:00

120 lines
5.3 KiB
Text

[% USE raw %]
[% USE Asset %]
[% USE KohaDates %]
[% USE Branches %]
[% USE Koha %]
[% USE HtmlTags %]
[% PROCESS 'i18n.inc' %]
[% SET footerjs = 1 %]
[% INCLUDE 'doc-head-open.inc' %]
<title>[% FILTER collapse %]
[% tx("Club enrollments for {club_name}", { club_name = club.name }) | html %] &rsaquo;
[% t("Patron clubs") | html %] &rsaquo;
[% t("Tools") | html %] &rsaquo;
[% t("Koha") | html %]
[% END %]</title>
[% INCLUDE 'doc-head-close.inc' %]
</head>
<body id="club_enrollments" class="clubs">
[% WRAPPER 'header.inc' %]
[% INCLUDE 'cat-search.inc' %]
[% END %]
[% WRAPPER 'sub-header.inc' %]
[% WRAPPER breadcrumbs %]
[% WRAPPER breadcrumb_item %]
<a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a>
[% END %]
[% WRAPPER breadcrumb_item %]
<a href="clubs.pl">Patron clubs</a>
[% END %]
[% WRAPPER breadcrumb_item bc_active= 1 %]
<span>Club enrollments for [% club.name | html | $HtmlTags tag="em" %]</span>
[% END %]
[% END #/ WRAPPER breadcrumbs %]
[% END #/ WRAPPER sub-header.inc %]
<div class="main container-fluid">
<div class="row">
<div class="col-sm-10 col-sm-push-2">
<main>
[% IF !club %]
<div class="dialog message">The club you requested does not exist.</div>
[% ELSE %]
<h1>Club enrollments for [% club.name | html | $HtmlTags tag="em" %]</h1>
<div class="page-section">
<table id="enrollments-table">
<thead>
<tr>
<th>Name</th>
<th>Card number</th>
[% FOREACH club_template_enrollment_field IN club.club_template.club_template_enrollment_fields %]
<th>[% club_template_enrollment_field.name | html %] </th>
[% END %]
</tr>
</thead>
<tbody>
[% FOREACH e IN club.club_enrollments %]
[% SET p = e.patron %]
<tr>
<td>
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% p.id | uri %]">[% p.surname | html %], [% p.firstname | html %]</a>
</td>
<td>
[% p.cardnumber | html %]
</td>
[% IF club_enrollment_fields %]
[% FOREACH club_enrollment_field IN club_enrollment_fields %]
[% IF e.id == club_enrollment_field.club_enrollment_id %]
[% FOREACH club_template_enrollment_field IN club.club_template.club_template_enrollment_fields %]
[% IF club_enrollment_field.club_template_enrollment_field_id == club_template_enrollment_field.id %]
[% IF club_template_enrollment_field.authorised_value_category %]
[% FOREACH a IN AuthorisedValues.Get( club_template_enrollment_field.authorised_value_category ) %]
[% IF a.authorised_value == club_enrollment_field.value %]
[% SET club_enrollment_field.value = a.lib %]
[% END %]
[% END %]
[% END %]
<td>[% club_enrollment_field.value | html %]</td>
[% END %]
[% END %]
[% END %]
[% END %]
[% END %]
</tr>
[% END %]
</tbody>
</table>
</div> <!-- /.page-section -->
[% END %]
</main>
</div> <!-- /.col-sm-10.col-sm-push-2 -->
<div class="col-sm-2 col-sm-pull-10">
<aside>
[% INCLUDE 'tools-menu.inc' %]
</aside>
</div> <!-- /.col-sm-2.col-sm-pull-10 -->
</div> <!-- /.row -->
[% MACRO jsinclude BLOCK %]
[% INCLUDE 'datatables.inc' %]
[% Asset.js("js/tools-menu.js") | $raw %]
<script>
$(document).ready(function() {
eTable = $('#enrollments-table').dataTable($.extend(true, {}, dataTablesDefaults, {
"sPaginationType": "full",
"sDom": 'C<"top pager"ilpf><"#filter_c">tr<"bottom pager"ip>',
"aoColumnDefs": [
{ "aTargets": [ -1, -2 ], "bSortable": false, "bSearchable": false },
]
} ));
});
</script>
[% END %]
[% INCLUDE 'intranet-bottom.inc' %]