Bugzilla – Attachment 7435 Details for
Bug 6968
Show items expired before today in check expiration of serials page
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
signed off patch
0001-Bug-6968-show-already-expired-subscriptions.patch (text/plain), 3.22 KB, created by
Adrien SAURAT
on 2012-02-03 10:28:58 UTC
(
hide
)
Description:
signed off patch
Filename:
MIME Type:
Creator:
Adrien SAURAT
Created:
2012-02-03 10:28:58 UTC
Size:
3.22 KB
patch
obsolete
>From 9df085a6df340768513517795866fb7180dbe749 Mon Sep 17 00:00:00 2001 >From: Maxime Pelletier <maxime.pelletier@libeo.com> >Date: Wed, 4 Jan 2012 11:53:49 -0500 >Subject: [PATCH] [SIGNED-OFF] Bug 6968: display of expired subscriptions > > >Signed-off-by: Adrien Saurat <adrien.saurat@biblibre.com> >--- > .../prog/en/modules/serials/checkexpiration.tt | 10 +++++++--- > serials/checkexpiration.pl | 7 +++++-- > 2 files changed, 12 insertions(+), 5 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 246eb49..e75b020 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >@@ -45,7 +45,7 @@ > <fieldset class="rows"> > <legend>Filter results :</legend> > >- <ol> >+ <ol> > <li><label for="title">Title:</label> > <input id="title" type="text" name="title" size="15" value="[% title %]" /></li> > >@@ -65,8 +65,12 @@ > ); > </script> <span class="required">Required</span> > <div class="hint">[% INCLUDE 'date-format.inc' %]</div></li> >- </ol> >- >+ <li> >+ <label for="showexpiredtoday">Show expired before today:</label> >+ <input id="showexpiredtoday" type="checkbox" name="showexpiredtoday" >+ [% IF ( showexpiredtoday ) %] checked="checked" [% END %]/> >+ </li> >+ </ol> > </fieldset> > <fieldset class="action"><input type="submit" value="Search" /></fieldset> > </form> >diff --git a/serials/checkexpiration.pl b/serials/checkexpiration.pl >index 02a4fbc..13ad042 100755 >--- a/serials/checkexpiration.pl >+++ b/serials/checkexpiration.pl >@@ -68,6 +68,7 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user ( > my $title = $query->param('title'); > my $issn = $query->param('issn'); > my $date = format_date_in_iso($query->param('date')); >+my $showexpiredtoday = $query->param('showexpiredtoday'); > > if ($date) { > my @subscriptions = GetSubscriptions( $title, $issn ); >@@ -78,9 +79,10 @@ if ($date) { > my $expirationdate = GetExpirationDate($subscriptionid); > > $subscription->{expirationdate} = $expirationdate; >- next if $expirationdate !~ /\d{4}-\d{2}-\d{2}/; # next if not in ISO format. >+ next if !$expirationdate || $expirationdate !~ /\d{4}-\d{2}-\d{2}/; # next if not in ISO format. > if ( Date_to_Days(split "-",$expirationdate) < Date_to_Days(split "-",$date) && >- Date_to_Days(split "-",$expirationdate) > Date_to_Days(&Today) ) { >+ (($showexpiredtoday && $showexpiredtoday eq 'on') || (Date_to_Days(split "-",$expirationdate) > Date_to_Days(&Today))) >+ ) { > $subscription->{expirationdate}=format_date($subscription->{expirationdate}); > push @subscriptions_loop,$subscription; > } >@@ -89,6 +91,7 @@ if ($date) { > $template->param ( > title => $title, > issn => $issn, >+ showexpiredtoday => $showexpiredtoday, > numsubscription => scalar @subscriptions_loop, > date => format_date($date), > subscriptions_loop => \@subscriptions_loop, >-- >1.7.4.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 6968
:
5702
|
5703
|
7038
|
7435
|
30703
|
35314