From 92473e8d7f835a74bbd726007c0f599fabccfe11 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Thu, 25 Mar 2021 18:05:13 +0000 Subject: [PATCH] Bug 28036: Improve breadcrumbs of serial claims page This patch modifies the serial claims script and templates so that better context can be shown in the page title and page breadcrumbs when a vendor has been selected. To test, apply the patch and go to Serials -> Claims. - The initial state of the page title and breadcrumbs should show "Serials > Claims." - Select a vendor. The page title and breadcrumbs show show "Serials > Claims > Claims for ." Signed-off-by: Lucas Gass Signed-off-by: Katrin Fischer --- .../prog/en/modules/serials/claims.tt | 25 ++++++++++++++++------ serials/claims.pl | 2 ++ 2 files changed, 20 insertions(+), 7 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/claims.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/claims.tt index a2dd7fec89..a9cffd0b70 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/claims.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/claims.tt @@ -4,7 +4,7 @@ [% USE Branches %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] - Koha › Serials › Claims + Koha › Serials › Claims [% IF ( supplierid ) -%] › Claims for [% suppliername | html %] [% END %] [% INCLUDE 'doc-head-close.inc' %] @@ -20,11 +20,22 @@
  • Serials
  • -
  • - - Claims - -
  • + [% IF ( supplierid ) -%] +
  • + + Claims + +
  • +
  • + Claims for [% suppliername | html %] +
  • + [% ELSE -%] +
  • + + Claims + +
  • + [% END %] @@ -33,7 +44,7 @@
    -

    Claims

    +

    Claims [% IF ( suppliername ) %] for [% suppliername | html %] [% END %]

    [% IF error_claim %] [% IF error_claim == 'no_vendor_email' %] diff --git a/serials/claims.pl b/serials/claims.pl index 4c6a2728a9..498f1cc2d9 100755 --- a/serials/claims.pl +++ b/serials/claims.pl @@ -84,11 +84,13 @@ my $letters = GetLetters({ module => 'claimissues' }); my @missingissues; if ($supplierid) { + my $supplier = Koha::Acquisition::Booksellers->find( $supplierid ); @missingissues = GetLateOrMissingIssues($supplierid); foreach my $issue (@missingissues) { $issue->{cannot_claim} = 1 unless C4::Serials::can_claim_subscription($issue); } + $template->param( suppliername => $supplier->name ); } $template->param( -- 2.11.0