Bugzilla – Attachment 3931 Details for
Bug 6195
manage tab in opac on serials
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Proposed Patch
0001-Bug-6195-Opac-user-should-not-have-serial-manage-tab.patch (text/plain), 2.83 KB, created by
Colin Campbell
on 2011-04-15 11:42:38 UTC
(
hide
)
Description:
Proposed Patch
Filename:
MIME Type:
Creator:
Colin Campbell
Created:
2011-04-15 11:42:38 UTC
Size:
2.83 KB
patch
obsolete
>From e260997753671a47830e2b831bd10eb3261da23e Mon Sep 17 00:00:00 2001 >From: Colin Campbell <colin.campbell@ptfs-europe.com> >Date: Fri, 15 Apr 2011 12:33:58 +0100 >Subject: [PATCH] Bug 6195 : Opac user should not have serial manage tab >Content-Type: text/plain; charset="utf-8" > >PrepareSerialData adds a year of 'manage' for staff display >Opac should not see this >Would be better if it returned a cleaner data structure and >let the template engine handle the display >--- > .../prog/en/modules/opac-full-serial-issues.tt | 7 +++++-- > opac/opac-serial-issues.pl | 13 ++++++++++--- > 2 files changed, 15 insertions(+), 5 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-full-serial-issues.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-full-serial-issues.tt >index 9cb5629..a74a4b5 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-full-serial-issues.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-full-serial-issues.tt >@@ -164,8 +164,11 @@ function showlayer(numlayer){ > </div> > > [% FOREACH year IN years %] >- [% IF ( year.first ) %] >- <div class="yeardata tabsub" id="show[% year.year %]" style="display:block">[% ELSE %]<div class="yeardata tabsub" id="show[% year.year %]" style="display:none">[% END %] >+ [% IF loop.first %] >+ <div class="yeardata tabsub" id="show[% year.year %]" style="display:block"> >+ [% ELSE %] >+ <div class="yeardata tabsub" id="show[% year.year %]" style="display:none"> >+ [% END %] > <table class="subscriptionstclass"> > <thead> > <tr> >diff --git a/opac/opac-serial-issues.pl b/opac/opac-serial-issues.pl >index 7b956f7..b534974 100755 >--- a/opac/opac-serial-issues.pl >+++ b/opac/opac-serial-issues.pl >@@ -54,6 +54,13 @@ if ( $selectview eq "full" ) { > ); > my $subscriptions = GetFullSubscriptionsFromBiblionumber($biblionumber); > my $subscriptioninformation=PrepareSerialsData($subscriptions); >+ # PrepareSerialsData does some bogus stuff that the template could handle >+ # But at least it sorts the array by the year field so we dont have to >+ # find 'manage' if its there >+ if ($subscriptioninformation->[0]->{year} eq 'manage') { >+ shift @{$subscriptioninformation}; >+ } >+ > # now, check is there is an alert subscription for one of the subscriptions > foreach (@$subscriptions) { > if (getalert($loggedinuser,'issue',$_->{subscriptionid})) { >@@ -61,9 +68,9 @@ if ( $selectview eq "full" ) { > } > } > >- my $title = $subscriptions->[0]{bibliotitle}; >- my $yearmin = $subscriptions->[0]{year}; >- my $yearmax = $subscriptions->[ scalar(@$subscriptions) - 1 ]{year}; >+ my $title = $subscriptions->[0]->{bibliotitle}; >+ my $yearmin = $subscriptions->[0]->{year}; >+ my $yearmax = $subscriptions->[ -1 ]->{year}; > > > # replace CR by <br> in librarian note >-- >1.7.4.2 >
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 6195
:
3929
| 3931 |
3932