Bugzilla – Attachment 149191 Details for
Bug 33410
Use template wrapper for breadcrumbs: Patron card creator
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33410: Use template wrapper for breadcrumbs: Patron card creator
Bug-33410-Use-template-wrapper-for-breadcrumbs-Pat.patch (text/plain), 16.03 KB, created by
Matt Blenkinsop
on 2023-04-05 10:19:38 UTC
(
hide
)
Description:
Bug 33410: Use template wrapper for breadcrumbs: Patron card creator
Filename:
MIME Type:
Creator:
Matt Blenkinsop
Created:
2023-04-05 10:19:38 UTC
Size:
16.03 KB
patch
obsolete
>From 5e8e3b4d7eeadca77ade7457028497b61720e9c9 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Tue, 4 Apr 2023 16:39:02 +0000 >Subject: [PATCH] Bug 33410: Use template wrapper for breadcrumbs: Patron card > creator > >This patch updates several patron card creator templates so that they >use the new WRAPPER for displaying breadcrumbs. > >Unrelated minor change: I added <span> around a few other strings in >edit-profile.tt and edit-template.tt in order to improve >translatability. > >To test, apply the patch and test each page and its variations. >Breadcrumbs should look correct, and each link should be correct. > >- Tools -> > - Patron card creator > - New -> > - Card batch > - Image > - Layout > - Card template > - Printer profile > - Manage -> > - Card batches > - Images > - Layouts > - Card templates > - Printer profiles > >Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> >--- > .../prog/en/modules/patroncards/edit-batch.tt | 43 +++++++--------- > .../en/modules/patroncards/edit-layout.tt | 40 +++++++-------- > .../en/modules/patroncards/edit-profile.tt | 49 ++++++++++--------- > .../en/modules/patroncards/edit-template.tt | 48 +++++++++--------- > .../prog/en/modules/patroncards/home.tt | 28 +++++------ > .../en/modules/patroncards/image-manage.tt | 30 ++++++------ > .../prog/en/modules/patroncards/manage.tt | 27 ++++------ > 7 files changed, 119 insertions(+), 146 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt >index 58615048b9..e83941a458 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-batch.tt >@@ -12,34 +12,27 @@ > [% END %] > > [% WRAPPER 'sub-header.inc' %] >- <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/manage.pl?card_element=batch">Batches</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- [% IF description %] >- <span>Edit [% description | html %]</span> >- [% ELSIF batch_id %] >- <span>Edit ([% batch_id | html %])</span> >- [% ELSE %] >- <span>New</span> >- [% END %] >- </a> >- </li> >- </ol> >- </nav> >- [% END %] >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ [% IF description %] >+ <span>Edit [% description | html %]</span> >+ [% ELSIF batch_id %] >+ <span>Edit ([% batch_id | html %])</span> >+ [% ELSE %] >+ <span>New</span> >+ [% END %] >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+ [% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-layout.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-layout.tt >index 4ccd13e469..5ab532b15e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-layout.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-layout.tt >@@ -1,3 +1,4 @@ >+[% USE raw %] > [% SET footerjs = 1 %] > [% INCLUDE 'doc-head-open.inc' %] > <title>[% IF ( layout_id ) %]Edit ([% layout_id | html %])[% ELSE %]New[% END %] › Layout › Patron card creator › Tools › Koha</title> >@@ -10,32 +11,25 @@ > [% END %] > > [% WRAPPER 'sub-header.inc' %] >- <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/manage.pl?card_element=layout">Layouts</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- [% IF ( layout_id ) %] >- Edit ([% layout_id | html %]) >- [% ELSE %] >- New >- [% END %] >- </a> >- </li> >- </ol> >- </nav> >- [% END %] >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ [% IF ( layout_id ) %] >+ <span>Edit ([% layout_id | html %])</span> >+ [% ELSE %] >+ <span>New</span> >+ [% END %] >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+ [% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-profile.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-profile.tt >index af4e464fd7..0d96f48745 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-profile.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-profile.tt >@@ -1,3 +1,4 @@ >+[% USE raw %] > [% SET footerjs = 1 %] > [% INCLUDE 'doc-head-open.inc' %] > <title>[% IF ( profile_id ) %]Edit ([% profile_id | html %])[% ELSE %]New[% END%] › Profiles › Patron card creator › Tools › Koha</title> >@@ -10,32 +11,25 @@ > [% END %] > > [% WRAPPER 'sub-header.inc' %] >- <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/manage.pl?card_element=profile">Profiles</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- [% IF ( profile_id ) %] >- Edit ([% profile_id | html %]) >- [% ELSE %] >- New >- [% END%] >- </a> >- </li> >- </ol> >- </nav> >- [% END %] >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ [% IF ( profile_id ) %] >+ <span>Edit ([% profile_id | html %])</span> >+ [% ELSE %] >+ <span>New</span> >+ [% END%] >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+ [% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >@@ -44,7 +38,14 @@ > > [% INCLUDE 'patroncards-toolbar.inc' %] > >- <h1>[% IF (profile_id) %]Edit[% ELSE %]Create[% END%] printer profile[% IF (profile_id) %] ([% profile_id | html %])[% END %]</h1> >+ <h1> >+ [% IF (profile_id) %] >+ <span>Edit printer profile</span> >+ [% ELSE %] >+ <span>Create printer profile</span> >+ [% END%] >+ [% IF (profile_id) %] ([% profile_id | html %])[% END %] >+ </h1> > <form name="input" action="/cgi-bin/koha/patroncards/edit-profile.pl" method="get"> > <fieldset class="rows"><legend>Profile settings</legend> > <ol> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-template.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-template.tt >index c4a2105973..8accfe9dae 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-template.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/edit-template.tt >@@ -12,32 +12,25 @@ > [% END %] > > [% WRAPPER 'sub-header.inc' %] >- <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/manage.pl?card_element=template">Templates</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- [% IF (template_id) %] >- Edit ([% template_id | html %]) >- [% ELSE %] >- New >- [% END %] >- </a> >- </li> >- </ol> >- </nav> >- [% END %] >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ [% IF (template_id) %] >+ <span>Edit ([% template_id | html %])</span> >+ [% ELSE %] >+ <span>New</span> >+ [% END %] >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+ [% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >@@ -45,7 +38,14 @@ > <main> > > [% INCLUDE 'patroncards-toolbar.inc' %] >- <h1>[% IF (template_id) %]Edit[% ELSE %]Create[% END %] patron card template[% IF (template_id) %] ([% template_id | html %])[% END %]</h1> >+ <h1> >+ [% IF (template_id) %] >+ <span>Edit patron card template</span> >+ [% ELSE %] >+ <span>Create patron card template</span> >+ [% END %] >+ [% IF (template_id) %] ([% template_id | html %])[% END %] >+ </h1> > <form name="input" action="/cgi-bin/koha/patroncards/edit-template.pl" method="get"> > <div class="row"> > <div class="col-sm-6"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/home.tt >index 1972d8e77b..1c47375bc9 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/home.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/home.tt >@@ -1,4 +1,4 @@ >- >+[% USE raw %] > [% INCLUDE 'doc-head-open.inc' %] > <title>Patron card creator › Tools › Koha</title> > [% INCLUDE 'doc-head-close.inc' %] >@@ -7,23 +7,17 @@ > [% WRAPPER 'header.inc' %] > [% INCLUDE 'cat-search.inc' %] > [% END %] >- [% WRAPPER 'sub-header.inc' %] >- <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ >+[% WRAPPER 'sub-header.inc' %] >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- Patron card creator >- </a> >- </li> >- </ol> >- </nav> >- [% END %] >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ <span>Patron card creator</span> >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+[% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/image-manage.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/image-manage.tt >index 9f39a0f848..022f80c8f4 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/image-manage.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/image-manage.tt >@@ -1,3 +1,4 @@ >+[% USE raw %] > [% SET footerjs = 1 %] > [% INCLUDE 'doc-head-open.inc' %] > <title>Images › Patron card creator › Tools › Koha</title> >@@ -8,24 +9,21 @@ > [% WRAPPER 'header.inc' %] > [% INCLUDE 'cat-search.inc' %] > [% END %] >-<nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ >+ >+[% WRAPPER 'sub-header.inc' %] >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- Images >- </a> >- </li> >- </ol> >-</nav> >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ <span>Images</span> >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+[% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt >index 9f7ad12130..1e4b5b8a9d 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt >@@ -34,25 +34,18 @@ > [% END %] > > [% WRAPPER 'sub-header.inc' %] >- <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb"> >- <ol> >- <li> >- <a href="/cgi-bin/koha/mainpage.pl">Home</a> >- </li> >- <li> >+ [% WRAPPER breadcrumbs %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> >- </li> >- <li> >+ [% END %] >+ [% WRAPPER breadcrumb_item %] > <a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a> >- </li> >- <li> >- <a href="#" aria-current="page"> >- [% PROCESS translate_card_element element=card_element_title %] >- </a> >- </li> >- </ol> >- </nav> >- [% END %] >+ [% END %] >+ [% WRAPPER breadcrumb_item bc_active= 1 %] >+ [% PROCESS translate_card_element element=card_element_title %] >+ [% END %] >+ [% END #/ WRAPPER breadcrumbs %] >+ [% END #/ WRAPPER sub-header.inc %] > > <div class="main container-fluid"> > <div class="row"> >-- >2.37.1 (Apple Git-137.1)
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 33410
:
149138
|
149191
|
149302