From fd28b02202aa2b47d23cb503ba1e63844638a928 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Sat, 6 May 2017 09:40:16 +0000 Subject: [PATCH] Bug 12349: Show card number in detailled suggestion pages MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This patch modifies the main suggestion management page to link patron names to their details rather than with a "mailto:" link. This patch also includes the following changes: - A fix for Bug 18154, Show card number in suggestion details view. - Changes for brevity to labels in the suggestion details & edit view. - Addition of the datepicker class to date fields in the suggestion edit view. Signed-off-by: Marc Véron Signed-off-by: Marcel de Rooy Signed-off-by: Jonathan Druart --- .../prog/en/modules/suggestion/suggestion.tt | 48 ++++++++++++------- suggestion/suggestion.pl | 1 + 2 files changed, 32 insertions(+), 17 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt index 85b0821d20..cbf951b76a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt @@ -305,20 +305,34 @@ h4.local_collapse a { font-size : 80%; text-decoration: none; } fieldset.brief o  DateBy - Suggestion creation + Created by: [% suggesteddate | $KohaDates %] - [% IF ( suggestedby_borrowernumber ) %][% suggestedby_surname %], [% suggestedby_firstname %] [% Branches.GetName( suggestedby_branchcode ) %] ([% suggestedby_description %])[% END %] + + [% IF ( suggestedby_borrowernumber ) %] + [% suggestedby_surname %], [% suggestedby_firstname %] ([% suggestedby_cardnumber %]) + [% Branches.GetName( suggestedby_branchcode ) %] ([% suggestedby_description %]) + [% END %] - Suggestion management + Managed by: [% manageddate | $KohaDates %] - [% IF ( managedby_borrowernumber ) %][% managedby_surname %], [% managedby_firstname %] [% Branches.GetName( managedby_branchcode ) %] ([% managedby_description %])[% END %] + + [% IF ( managedby_borrowernumber ) %] + [% managedby_surname %], [% managedby_firstname %] ([% suggestedby_cardnumber %]) + [% Branches.GetName( managedby_branchcode ) %] ([% managedby_description %]) + [% END %] + - Suggestion accepted + Accepted on: [% accepteddate | $KohaDates %] - [% IF ( acceptedby_borrowernumber ) %][% acceptedby_surname %], [% acceptedby_firstname %] [% Branches.GetName( acceptedby_branchcode ) %] ([% acceptedby_description %])[% END %] + + [% IF ( acceptedby_borrowernumber ) %] + [% acceptedby_surname %], [% acceptedby_firstname %] ([% suggestedby_cardnumber %]) + [% Branches.GetName( acceptedby_branchcode ) %] ([% acceptedby_description %]) + [% END %] + @@ -448,20 +462,20 @@ h4.local_collapse a { font-size : 80%; text-decoration: none; } fieldset.brief o  DateBy - - - [% IF ( suggestedby_borrowernumber ) %][% suggestedby_surname %], [% suggestedby_firstname %] [% Branches.GetName( suggestedby_branchcode ) %] ([% suggestedby_description %])[% END %] + + [% INCLUDE 'date-format.inc' %] + [% IF ( suggestedby_borrowernumber ) %][% suggestedby_surname %], [% suggestedby_firstname %] ([% suggestedby_cardnumber %]) [% Branches.GetName( suggestedby_branchcode ) %] ([% suggestedby_description %])[% END %] - - - [% IF ( managedby_borrowernumber ) %][% managedby_surname %], [% managedby_firstname %] [% Branches.GetName( managedby_branchcode ) %] ([% managedby_description %])[% END %] + + [% INCLUDE 'date-format.inc' %] + [% IF ( managedby_borrowernumber ) %][% managedby_surname %], [% managedby_firstname %] ([% suggestedby_cardnumber %]) [% Branches.GetName( managedby_branchcode ) %] ([% managedby_description %])[% END %] - - - [% IF ( acceptedby_borrowernumber ) %][% acceptedby_surname %], [% acceptedby_firstname %] [% Branches.GetName( acceptedby_branchcode ) %] ([% acceptedby_description %])[% END %] + + [% INCLUDE 'date-format.inc' %] + [% IF ( acceptedby_borrowernumber ) %][% acceptedby_surname %], [% acceptedby_firstname %] ([% suggestedby_cardnumber %]) [% Branches.GetName( acceptedby_branchcode ) %] ([% acceptedby_description %])[% END %] @@ -596,11 +610,11 @@ h4.local_collapse a { font-size : 80%; text-decoration: none; } fieldset.brief o [% IF ( suggestions_loo.isbn ) %]; ISBN:[% suggestions_loo.isbn |html %] [% END %][% IF ( suggestions_loo.publishercode ) %]; Published by [% suggestions_loo.publishercode |html %] [% END %][% IF ( suggestions_loo.publicationyear ) %] in [% suggestions_loo.publicationyear |html %] [% END %][% IF ( suggestions_loo.place ) %] in [% suggestions_loo.place |html %] [% END %][% IF ( suggestions_loo.collectiontitle ) %]; [% suggestions_loo.collectiontitle |html %] [% END %][% IF ( suggestions_loo.itemtype ) %]; [% AuthorisedValues.GetByCode( 'SUGGEST_FORMAT', suggestions_loo.itemtype, 0 ) %] [% END %]
[% IF ( suggestions_loo.note ) %][% suggestions_loo.note |html%][% END %] - [% IF ( suggestions_loo.emailsuggestedby ) %][% END %][% suggestions_loo.surnamesuggestedby %][% IF ( suggestions_loo.firstnamesuggestedby ) %], [% suggestions_loo.firstnamesuggestedby %][% END %] [% IF (suggestions_loo.cardnumbersuggestedby ) %]([% suggestions_loo.cardnumbersuggestedby %])[% END %] [% IF ( suggestions_loo.emailsuggestedby ) %][% END %] + [% suggestions_loo.surnamesuggestedby %][% IF ( suggestions_loo.firstnamesuggestedby ) %], [% suggestions_loo.firstnamesuggestedby %][% END %] [% IF (suggestions_loo.cardnumbersuggestedby ) %]([% suggestions_loo.cardnumbersuggestedby %])[% END %] [% IF ( suggestions_loo.suggesteddate ) %] - [% suggestions_loo.suggesteddate | $KohaDates %][% END %] - [% IF ( suggestions_loo.emailmanagedby ) %][% END %][% suggestions_loo.surnamemanagedby %][% IF ( suggestions_loo.firstnamemanagedby ) %], [% suggestions_loo.firstnamemanagedby %][% END %] [% IF ( suggestions_loo.emailmanagedby ) %][% END %] + [% suggestions_loo.surnamemanagedby %][% IF ( suggestions_loo.firstnamemanagedby ) %], [% suggestions_loo.firstnamemanagedby %][% END %] [% IF ( suggestions_loo.manageddate ) %] - [% suggestions_loo.manageddate | $KohaDates %][% END %] diff --git a/suggestion/suggestion.pl b/suggestion/suggestion.pl index a897ca6bfe..c291534fa4 100755 --- a/suggestion/suggestion.pl +++ b/suggestion/suggestion.pl @@ -288,6 +288,7 @@ foreach my $element ( qw(managedby suggestedby acceptedby) ) { $element."_borrowernumber"=>$patron->borrowernumber, $element."_firstname"=>$patron->firstname, $element."_surname"=>$patron->surname, + $element."_cardnumber"=>$patron->cardnumber, $element."_branchcode"=>$patron->branchcode, $element."_description"=>$category->description, $element."_category_type"=>$category->category_type, -- 2.39.5