Bugzilla – Attachment 44734 Details for
Bug 15171
Searching serials expiring after today should be allowed
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15171: Display subscriptions which will expire in the future
Bug-15171-Display-subscriptions-which-will-expire-.patch (text/plain), 2.74 KB, created by
Marc Véron
on 2015-11-11 10:41:06 UTC
(
hide
)
Description:
Bug 15171: Display subscriptions which will expire in the future
Filename:
MIME Type:
Creator:
Marc Véron
Created:
2015-11-11 10:41:06 UTC
Size:
2.74 KB
patch
obsolete
>From 125ce185432fc5fb6ccb238c42d68af674d03037 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 11 Nov 2015 09:36:16 +0000 >Subject: [PATCH] Bug 15171: Display subscriptions which will expire in the > future >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >Since the form on the subscription check expiration page let the user choose an >expiration date > today, there is no sense to hide subscriptions which will expire in the future. > >Test plan: >0/ Make sure you have at least subscription with an expiration date > today >1/ Start a seach on the check expiration page (serials/checkexpiration.pl) >with a date < today, = today and > today >=> The subscription won't never be displayed without this patch. >With this patch, it will. > >Note that you will get a "No results for your query" message only if you >have search for something. > >Followed testplan, works as expected. >Signed-off-by: Marc Véron <veron@veron.ch> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt | 2 +- > serials/checkexpiration.pl | 4 ++-- > 2 files changed, 3 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >index 551338a..e41d5c3 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >@@ -134,7 +134,7 @@ > </tr> > [% END %] > </table> >-[% ELSE %] >+[% ELSIF searched %] > <p>No results for your query</p> > [% END %] > >diff --git a/serials/checkexpiration.pl b/serials/checkexpiration.pl >index c926814..11d1714 100755 >--- a/serials/checkexpiration.pl >+++ b/serials/checkexpiration.pl >@@ -51,7 +51,7 @@ use C4::Branch; > use C4::Output; > use C4::Context; > use C4::Dates qw/format_date format_date_in_iso/; >-use Date::Calc qw/Today Date_to_Days/; >+use Date::Calc qw/Date_to_Days/; > > my $query = new CGI; > >@@ -90,7 +90,6 @@ if ($date) { > } > next if $subscription->{cannotedit}; > if ( Date_to_Days(split "-",$expirationdate) < Date_to_Days(split "-",$date) && >- Date_to_Days(split "-",$expirationdate) > Date_to_Days(&Today) && > ( !$branch || ($subscription->{'branchcode'} eq $branch) ) ) { > $subscription->{expirationdate}=format_date($subscription->{expirationdate}); > push @subscriptions_loop,$subscription; >@@ -104,6 +103,7 @@ if ($date) { > date => format_date($date), > subscriptions_loop => \@subscriptions_loop, > "BiblioDefaultView".C4::Context->preference("BiblioDefaultView") => 1, >+ searched => 1, > ); > } > >-- >1.7.10.4
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 15171
:
44730
|
44734
|
44783