Bugzilla – Attachment 30703 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]
check expiration in serials expired before today
Bug-6968-show-already-expired-subscriptions.patch (text/plain), 2.67 KB, created by
Charles Farmer
on 2014-08-11 15:07:35 UTC
(
hide
)
Description:
check expiration in serials expired before today
Filename:
MIME Type:
Creator:
Charles Farmer
Created:
2014-08-11 15:07:35 UTC
Size:
2.67 KB
patch
obsolete
>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 95bfcb8..5fb909d 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt >@@ -46,6 +46,7 @@ > <legend>Filter results :</legend> > > <ol> >+ <ol> > <li><label for="title">Title:</label> > <input id="title" type="text" name="title" size="15" value="[% title %]" /></li> > >@@ -57,7 +58,13 @@ > <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 e24210f..695b3c0 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,10 +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. > next if $subscription->{closed}; > if ( Date_to_Days(split "-",$expirationdate) < Date_to_Days(split "-",$date) && >- Date_to_Days(split "-",$expirationdate) > Date_to_Days(&Today) ) { >+ ( $showexpiredtoday || (Date_to_Days(split "-",$expirationdate) > Date_to_Days(&Today)))) { > $subscription->{expirationdate}=format_date($subscription->{expirationdate}); > push @subscriptions_loop,$subscription; > } >@@ -90,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,
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