Bug 16530: Adding a circ sidebar navigation menu and circSidebar syspref to activate...
authorAleisha <aleishaamohia@hotmail.com>
Tue, 17 May 2016 04:35:46 +0000 (04:35 +0000)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 3 Mar 2017 18:34:36 +0000 (18:34 +0000)
Edit: Fast cataloging link should now show on all pages, removed offline circulation links
Edit 2: Creates the syspref to activate or deactivate the sidebar
Edit 3: Fixing merge conflicts, using Koha::BiblioFrameworks to find FA
framework and adding sidebar to on-site checkouts

This adds a sidebar to
circ/branchoverdues.tt
circ/circulation.tt (I also fixed up some of the indentation in this file to make it easier to see where the divs started and ended)
circ/renew.tt
circ/returns.tt
circ/selectbranchprinter.tt
circ/transferstoreceive.tt
circ/view_holdsqueue.tt
circ/waitingreserves.tt
circ/branchtransfers.tt
circ/on-site_checkouts.tt

To test:
1) Confirm syspref CircSidebar is activated
2) Go to all of the above pages and confirm the sidebar menu shows up
3) Confirm fast cataloguing link and transfer link are there
4) Trigger any error messages you can possibly think of (i.e. on renew.pl: barcode does not exist). Confirm that this does not mess up the layout of the page
5) Go to a user account page, Check out tab. (Since this is a circ/circulation.pl page). Ensure the circ nav sidebar doesn't show up (confirm it looks as it usually does)
6) Deactivate circSidebar
7) Confirm pages all look normal

Sponsored-by: Catalyst IT
Signed-off-by: Jan Kissig <jkissig@th-wildau.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
23 files changed:
circ/branchoverdues.pl
circ/branchtransfers.pl
circ/on-site_checkouts.pl
circ/renew.pl
circ/returns.pl
circ/selectbranchprinter.pl
circ/transferstoreceive.pl
circ/view_holdsqueue.pl
circ/waitingreserves.pl
installer/data/mysql/atomicupdate/bug_16530-add_CircSidebar_syspref.sql [new file with mode: 0644]
installer/data/mysql/sysprefs.sql
koha-tmpl/intranet-tmpl/prog/en/includes/circ-nav.inc [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref
koha-tmpl/intranet-tmpl/prog/en/modules/circ/branchoverdues.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/branchtransfers.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/on-site_checkouts.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/renew.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/selectbranchprinter.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/transferstoreceive.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt
koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tt

index 86f9cca..fe96caa 100755 (executable)
@@ -27,6 +27,7 @@ use C4::Biblio;
 use C4::Koha;
 use C4::Debug;
 use Koha::DateUtils;
+use Koha::BiblioFrameworks;
 use Data::Dumper;
 
 =head1 branchoverdues.pl
@@ -61,7 +62,7 @@ use Data::Dumper;
 my $input       = new CGI;
 my $dbh = C4::Context->dbh;
 
-my ( $template, $loggedinuser, $cookie ) = get_template_and_user({
+my ( $template, $loggedinuser, $cookie, $flags ) = get_template_and_user({
         template_name   => "circ/branchoverdues.tt",
         query           => $input,
         type            => "intranet",
@@ -155,4 +156,10 @@ $template->param(
     location     => $location,
 );
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 output_html_with_http_headers $input, $cookie, $template->output;
index 864db53..64a5c10 100755 (executable)
@@ -31,7 +31,7 @@ use C4::Items;
 use C4::Auth qw/:DEFAULT get_session/;
 use C4::Koha;
 use C4::Members;
-
+use Koha::BiblioFrameworks;
 use Koha::AuthorisedValues;
 
 ###############################################
@@ -52,7 +52,7 @@ if (!C4::Context->userenv){
 
 #######################################################################################
 # Make the page .....
-my ($template, $user, $cookie) = get_template_and_user(
+my ($template, $user, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/branchtransfers.tt",
         query           => $query,
@@ -236,5 +236,12 @@ $template->param(
     errmsgloop              => \@errmsgloop,
     CircAutocompl           => C4::Context->preference("CircAutocompl")
 );
+
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 output_html_with_http_headers $query, $cookie, $template->output;
 
index 2ae52f7..cf630c9 100755 (executable)
@@ -21,10 +21,12 @@ use Modern::Perl;
 use C4::Auth;
 use C4::Circulation qw( GetPendingOnSiteCheckouts );
 use C4::Output;
+use C4::Koha;
+use Koha::BiblioFrameworks;
 
 my $cgi = new CGI;
 
-my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
+my ( $template, $loggedinuser, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/on-site_checkouts.tt",
         query           => $cgi,
@@ -34,6 +36,12 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
     }
 );
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 my $pending_onsite_checkouts = C4::Circulation::GetPendingOnSiteCheckouts();
 
 $template->param(
index 2b4114e..d68247e 100755 (executable)
@@ -24,12 +24,14 @@ use C4::Context;
 use C4::Auth qw/:DEFAULT get_session/;
 use C4::Output;
 use C4::Circulation;
+use C4::Koha;
 use Koha::DateUtils;
 use Koha::Database;
+use Koha::BiblioFrameworks;
 
 my $cgi = new CGI;
 
-my ( $template, $librarian, $cookie ) = get_template_and_user(
+my ( $template, $librarian, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/renew.tt",
         query           => $cgi,
@@ -116,4 +118,10 @@ if ($barcode) {
     );
 }
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 output_html_with_http_headers( $cgi, $cookie, $template->output );
index 5382e19..1409fe7 100755 (executable)
@@ -51,11 +51,12 @@ use Koha::AuthorisedValues;
 use Koha::DateUtils;
 use Koha::Calendar;
 use Koha::Checkouts;
+use Koha::BiblioFrameworks;
 
 my $query = new CGI;
 
 #getting the template
-my ( $template, $librarian, $cookie ) = get_template_and_user(
+my ( $template, $librarian, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/returns.tt",
         query           => $query,
@@ -648,5 +649,11 @@ if ( $itemnumber ) {
     }
 }
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 # actually print the page!
 output_html_with_http_headers $query, $cookie, $template->output;
index e037e9e..cf0af68 100755 (executable)
@@ -26,14 +26,14 @@ use C4::Output;
 use C4::Auth qw/:DEFAULT get_session/;
 use C4::Print;  # GetPrinters
 use C4::Koha;
-
+use Koha::BiblioFrameworks;
 use Koha::Libraries;
 
 # this will be the script that chooses branch and printer settings....
 
 my $query = CGI->new();
 
-my ( $template, $borrowernumber, $cookie ) = get_template_and_user({
+my ( $template, $borrowernumber, $cookie, $flags ) = get_template_and_user({
     template_name   => "circ/selectbranchprinter.tt",
     query           => $query,
     type            => "intranet",
@@ -134,4 +134,10 @@ $template->param(
     recycle_loop=> \@recycle_loop,
 );
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 output_html_with_http_headers $query, $cookie, $template->output;
index a67f799..3f89f59 100755 (executable)
@@ -24,7 +24,6 @@ use CGI qw ( -utf8 );
 use C4::Context;
 use C4::Output;
 use C4::Auth;
-use Koha::DateUtils;
 use C4::Biblio;
 use C4::Circulation;
 use C4::Members;
@@ -37,11 +36,13 @@ use Date::Calc qw(
 use C4::Koha;
 use C4::Reserves;
 use Koha::Libraries;
+use Koha::DateUtils;
+use Koha::BiblioFrameworks;
 
 my $input = new CGI;
 my $itemnumber = $input->param('itemnumber');
 
-my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
+my ( $template, $loggedinuser, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/transferstoreceive.tt",
         query           => $input,
@@ -124,5 +125,11 @@ $template->param(
        latetransfers => $latetransfers ? 1 : 0,
 );
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 output_html_with_http_headers $input, $cookie, $template->output;
 
index ce632e6..6738c70 100755 (executable)
@@ -31,9 +31,10 @@ use C4::Biblio;
 use C4::Items;
 use C4::Koha;   # GetItemTypes
 use C4::HoldsQueue qw(GetHoldsQueueItems);
+use Koha::BiblioFrameworks;
 
 my $query = new CGI;
-my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
+my ( $template, $loggedinuser, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/view_holdsqueue.tt",
         query           => $query,
@@ -74,5 +75,11 @@ $template->param(
    itemtypeloop => \@itemtypesloop,
 );
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 # writing the template
 output_html_with_http_headers $query, $cookie, $template->output;
index 1a7b29c..6f12376 100755 (executable)
@@ -28,7 +28,6 @@ use C4::Circulation;
 use C4::Members;
 use C4::Biblio;
 use C4::Items;
-use Koha::DateUtils;
 use Date::Calc qw(
   Today
   Add_Delta_Days
@@ -36,6 +35,8 @@ use Date::Calc qw(
 );
 use C4::Reserves;
 use C4::Koha;
+use Koha::DateUtils;
+use Koha::BiblioFrameworks;
 
 my $input = new CGI;
 
@@ -47,7 +48,7 @@ my $all_branches   = $input->param('allbranches') || '';
 my $cancelall      = $input->param('cancelall');
 my $tab            = $input->param('tab');
 
-my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
+my ( $template, $loggedinuser, $cookie, $flags ) = get_template_and_user(
     {
         template_name   => "circ/waitingreserves.tt",
         query           => $input,
@@ -163,6 +164,12 @@ $template->param(
     tab => $tab,
 );
 
+# Checking if there is a Fast Cataloging Framework
+$template->param( fast_cataloging => 1 ) if Koha::BiblioFrameworks->find( 'FA' );
+
+# Checking if the transfer page needs to be displayed
+$template->param( display_transfer => 1 ) if ( ($flags->{'superlibrarian'} == 1) || (C4::Context->preference("IndependentBranches") == 0) );
+
 if ($item && $tab eq 'holdsover' && !@cancel_result) {
     print $input->redirect("/cgi-bin/koha/circ/waitingreserves.pl#holdsover");
 } elsif ($cancelall) {
diff --git a/installer/data/mysql/atomicupdate/bug_16530-add_CircSidebar_syspref.sql b/installer/data/mysql/atomicupdate/bug_16530-add_CircSidebar_syspref.sql
new file mode 100644 (file)
index 0000000..09a8e4b
--- /dev/null
@@ -0,0 +1 @@
+INSERT IGNORE INTO systempreferences (`variable`, `value`, `options`, `explanation`, `type`) VALUES ('CircSidebar','0','','Activate or deactivate the navigation sidebar on all Circulation pages','YesNo');
index e46e29f..1aa3f8d 100644 (file)
@@ -102,6 +102,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `
 ('CircAutocompl','1',NULL,'If ON, autocompletion is enabled for the Circulation input','YesNo'),
 ('CircAutoPrintQuickSlip','qslip',NULL,'Choose what should happen when an empty barcode field is submitted in circulation: Display a print quick slip window, Display a print slip window or Clear the screen.','Choice'),
 ('CircControl','ItemHomeLibrary','PickupLibrary|PatronLibrary|ItemHomeLibrary','Specify the agency that controls the circulation and fines policy','Choice'),
+('CircSidebar','0',NULL,'Activate or deactivate the navigation sidebar on all Circulation pages','YesNo'),
 ('ClaimsBccCopy','0','','Bcc the ClaimAcquisition and ClaimIssues alerts','YesNo'),
 ('Coce','0', NULL, 'If on, enables cover retrieval from the configured Coce server', 'YesNo'),
 ('CoceHost', '', NULL, 'Coce server URL', 'Free'),
diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/circ-nav.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/circ-nav.inc
new file mode 100644 (file)
index 0000000..7bcd94c
--- /dev/null
@@ -0,0 +1,54 @@
+<script type="text/javascript">//<![CDATA[
+    $(document).ready(function() {
+        var path = location.pathname.substring(1);
+        var url = window.location.toString();
+        var params = '';
+        if ( url.match(/\?(.+)$/) ) {
+            params = "?" + RegExp.$1;
+        }
+        $('#navmenulist a[href$="/' + path + params + '"]').css('font-weight','bold');
+    });
+//]]>
+</script>
+
+<div id="navmenu">
+    <div id="navmenulist">
+
+        <ul>
+            <li><a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation home</a></li>
+        </ul>
+
+        <h5>Circulation</h5>
+        <ul>
+            <li><a href="/cgi-bin/koha/circ/circulation.pl">Check out</a></li>
+            <li><a href="/cgi-bin/koha/circ/returns.pl">Check in</a></li>
+            <li><a href="/cgi-bin/koha/circ/renew.pl">Renew</a></li>
+            [% IF ( display_transfer ) %]
+                <li><a href="/cgi-bin/koha/circ/branchtransfers.pl">Transfer</a></li>
+            [% END %]
+            [% IF ( AutoLocation ) %][% ELSE %][% IF ( IndependentBranches ) %][% ELSE %]
+                <li><a href="/cgi-bin/koha/circ/selectbranchprinter.pl">Set library</a></li>
+            [% END %][% END %]
+            [% IF ( fast_cataloging ) %][% IF ( CAN_user_editcatalogue_fast_cataloging ) %]
+                <li><a href="/cgi-bin/koha/cataloguing/addbiblio.pl?frameworkcode=FA">Fast cataloging</a></li>
+            [% END %][% END %]
+        </ul>
+
+        <h5>Circulation reports</h5>
+        <ul>
+            <li><a href="/cgi-bin/koha/circ/view_holdsqueue.pl">Holds queue</a></li>
+            <li><a href="/cgi-bin/koha/circ/pendingreserves.pl">Holds to pull</a></li>
+            <li><a href="/cgi-bin/koha/circ/waitingreserves.pl">Holds awaiting pickup</a></li>
+            <li><a href="/cgi-bin/koha/circ/reserveratios.pl">Hold ratios</a></li>
+            <li><a href="/cgi-bin/koha/circ/transferstoreceive.pl">Transfers to receive</a></li>
+            [% IF ( CAN_user_circulate_overdues_report ) %]
+                <li><a href="/cgi-bin/koha/circ/overdue.pl">Overdues</a></li>
+            [% END %]
+            <li><a href="/cgi-bin/koha/circ/branchoverdues.pl">Overdues with fines</a></li>
+            [% IF Koha.Preference('OnSiteCheckouts') %]
+                <li><a href="/cgi-bin/koha/circ/on-site_checkouts.pl">Pending on-site checkouts</a></li>
+            [% END %]
+        </ul>
+
+    </div>
+</div>
index dfbcd8d..81b671c 100644 (file)
@@ -2,6 +2,12 @@ Circulation:
 # FIXME: printcirculationslips is also omitted. It _technically_ could work, but C4::Print is HLT specific and needs a little bit of refactoring.
     Interface:
         -
+            - pref: CircSidebar
+              choices:
+                  yes: Activate
+                  no: Deactivate
+            - the navigation sidebar on all Circulation pages.
+        -
             - pref: CircAutocompl
               choices:
                   yes: Try
index 88329f9..5a50369 100644 (file)
@@ -1,4 +1,5 @@
 [% USE Branches %]
+[% USE Koha %]
 [% INCLUDE 'doc-head-open.inc' %]
 <title>Koha &rsaquo; Circulation &rsaquo; Overdues at [% LoginBranchname %]</title>
 [% INCLUDE 'doc-head-close.inc' %]
 
 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Overdues at [% LoginBranchname %]</div>
 
-<div id="doc" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
 
    <div id="bd">
        <div id="yui-main">
+        [% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
        <div class="yui-g">
 
 
 
 </div>
 </div>
+[% IF Koha.Preference('CircSidebar') %]
+</div>
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
 </div>
 [% INCLUDE 'intranet-bottom.inc' %]
index ede0767..d1a3be5 100644 (file)
 
 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Transfers</div>
 
-<div id="doc" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
    <div id="bd">
-
+<div id="yui-main">
+[% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
 [% IF ( found ) %]
    <div class="yui-g"> <h3>Reserve found</h3>
     <table>
        
        
 [% END %]
-
+</div>
+[% IF Koha.Preference('CircSidebar') %]
+<div class="yui-b noprint">
+[% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
+</div>
 </div>
 [% INCLUDE 'intranet-bottom.inc' %]
index d6608d7..114f2e7 100644 (file)
@@ -1005,12 +1005,24 @@ No patron matched <span class="ex">[% message | html %]</span>
 [% END %] <!-- borrowernumber and borrower-->
 </div></div>
 [% END %]
-
+[% IF Koha.Preference('CircSidebar') %]
+[% UNLESS ( borrowers ) %]
+    [% IF not( borrowernumber and borrower ) %]
+        <div class="yui-b noprint">
+            [% INCLUDE 'circ-nav.inc' %]
+        </div>
+    [% END %]
+[% END %]
+[% END %]
 </div>
 </div>
-[% UNLESS ( borrowers ) %][% IF borrowernumber and borrower %]<div class="yui-b">
-[% INCLUDE 'circ-menu.inc' %]
-</div>[% END %][% END %]
+[% UNLESS ( borrowers ) %]
+    [% IF borrowernumber and borrower %]
+        <div class="yui-b">
+            [% INCLUDE 'circ-menu.inc' %]
+        </div>
+    [% END %]
+[% END %]
 </div>
 <!-- Modal -->
 <div id="barcodeSubmittedModal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="barcodeSubmittedModalLabel" aria-hidden="true">
index 483c24e..648225c 100644 (file)
@@ -1,3 +1,4 @@
+[% USE Koha %]
 [% USE Branches %]
 [% USE KohaDates %]
 [% USE AuthorisedValues %]
@@ -79,7 +80,7 @@ $(document).ready(function(){
       </div>
     </div>
     <div class="yui-b">
-      [% INCLUDE 'circ-menu.inc' %]
+      [% IF Koha.Preference('CircSidebar') %][% INCLUDE 'circ-nav.inc' %][% END %]
     </div>
   </div>
 [% INCLUDE 'intranet-bottom.inc' %]
index acac079..b63d7a4 100644 (file)
 
 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Renew</div>
 
-<div id="doc" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
     <div id="bd">
-
+        <div id="yui-main">
+            [% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
                 [% IF error %]
                     <div class="dialog alert">
                         <h3>Cannot renew:</h3>
                         </p>
                     </div>
                 [% END %]
-            </div>
 
             <div class="yui-g">
 
             [% END %]
 
         </div>
-
     </div>
 
+[% IF Koha.Preference('CircSidebar') %]
+</div>
+
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
 <div>
 
 [% INCLUDE 'intranet-bottom.inc' %]
index 50a65d5..702a039 100644 (file)
@@ -155,11 +155,11 @@ $(document).ready(function () {
 
 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Check in</div>
 
-<div id="doc" class="yui-t7">
-
-   <div id="bd">
-       <div id="yui-main">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
 
+<div id="bd">
+<div id="yui-main">
+[% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
 <div class="yui-g">
 
 [% IF privacy == 2 AND NOT Koha.Preference('AnonymousPatron') %]
@@ -634,15 +634,48 @@ $(document).ready(function () {
                     [% END %]
                     [% IF ( errmsgloo.prevdebarred ) %]
                         <p class="problem"><b>Reminder: </b>Patron was earlier restricted until [% errmsgloo.prevdebarred | $KohaDates %].</p>
-                    [% END %]
-                    [% IF ( errmsgloo.foreverdebarred ) %]
-                        <p class="problem"><b>Reminder: </b>Patron has an indefinite restriction.</p>
-                    [% END %]
-
             [% END %]
-        [% ELSE %]
+            [% IF ( errmsgloo.badbarcode ) %]
+                <p class="problem">No item with barcode: [% errmsgloo.msg %]</p>
+            [% END %]
+            [% IF ( errmsgloo.ispermanent ) %]
+                <p class="problem">Please return item to: [% errmsgloo.msg %]</p>
+            [% END %]
+            [% IF ( errmsgloo.notissued ) %]
+                <p class="problem">Not checked out.</p>
+            [% END %]
+            [% IF ( errmsgloo.localuse) %]
+                <p class="problem">Local use recorded</p>
+            [% END %]
+            [% IF ( errmsgloo.waslost ) %]
+                <p class="problem">Item was lost, now found.</p>
+                [% IF ( LostItemFeeRefunded ) %]
+                    <p class="problem">A refund has been applied to the borrowing patron's account.</p>
+                [% ELSE %]
+                    <p class="problem">Any lost item fees for this item will remain on the patron's account.</p>
+                [% END %]
+            [% END %]
+            [% IF ( errmsgloo.withdrawn ) %]
+                [% IF BlockReturnOfWithdrawnItems %]
+                    <h5>Cannot check in</h5>
+                    <p><strong>NOT CHECKED IN</strong></p>
+                    <p class="problem">Item is withdrawn.</p>
+                [% ELSE %]
+                    <p class="problem">Item is withdrawn.</p>
+                [% END %]
+            [% END %]
+            [% IF ( errmsgloo.debarred ) %]
+                <p class="problem"><a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% errmsgloo.debarborrowernumber %]">[% errmsgloo.debarname %]([% errmsgloo.debarcardnumber %])</a> is now debarred until [% errmsgloo.debarred | $KohaDates %].</p>
+            [% END %]
+            [% IF ( errmsgloo.prevdebarred ) %]
+                <p class="problem"><b>Reminder: </b>Patron was earlier restricted until [% errmsgloo.prevdebarred | $KohaDates %].</p>
+            [% END %]
+            [% IF ( errmsgloo.foreverdebarred ) %]
+                <p class="problem"><b>Reminder: </b>Patron has an indefinite restriction.</p>
+            [% END %]
         [% END %]
     </div>
+[% END %]
 
 [% IF ( checkinmsg ) %]
     [% IF ( checkinmsgtype == 'alert' ) %]
@@ -664,7 +697,7 @@ $(document).ready(function () {
         <p>Book drop mode.  (Effective checkin date is [% dropboxdate %] ).</p>
     </div>
 </div>
-       <div class="yui-g">
+<div class="yui-g">
     <form id="checkin-form" method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off" >
     <div class="yui-u first">
             <fieldset>
@@ -791,9 +824,16 @@ $(document).ready(function () {
             </td>
            </tr>
         [% END %]
-    </table></div>
+    </table>
 [% END %]
-
-
+</div>
+[% IF Koha.Preference('CircSidebar') %]
+</div>
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
+</div>
+</div>
 </div>
 [% INCLUDE 'intranet-bottom.inc' %]
index 4b3933d..220e5b0 100644 (file)
@@ -1,4 +1,5 @@
 [% USE Branches %]
+[% USE Koha %]
 [% INCLUDE 'doc-head-open.inc' %]
 <title>Koha &rsaquo; Circulation &rsaquo; Set library</title>
 [% INCLUDE 'doc-head-close.inc' %]
@@ -16,7 +17,7 @@
 &rsaquo; <a href="/cgi-bin/koha/circ/selectbranchprinter.pl">Set library</a>
 </div>
 
-<div id="doc" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
   <div id="bd">
     <div id="yui-main">
       <div class="yui-b">
@@ -89,5 +90,10 @@ Updated:<ul>
 
       </div>
     </div>
-  </div>
+[% IF Koha.Preference('CircSidebar') %]
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
+</div>
 [% INCLUDE 'intranet-bottom.inc' %]
index fc3a91f..8b82028 100644 (file)
@@ -1,3 +1,4 @@
+[% USE Koha %]
 [% USE KohaDates %]
 [% USE Branches %]
 [% INCLUDE 'doc-head-open.inc' %]
@@ -29,10 +30,11 @@ $(document).ready(function() {
 
 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a>  &rsaquo; Transfers to receive</div>
 
-<div id="doc" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
 
    <div id="bd">
        <div id="yui-main">
+        [% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
        <div class="yui-g">
 
         <h1>Transfers made to your library as of [% show_date | $KohaDates %]</h1>
@@ -95,5 +97,11 @@ $(document).ready(function() {
 
 </div>
 </div>
+[% IF Koha.Preference('CircSidebar') %]
+</div>
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
 </div>
 [% INCLUDE 'intranet-bottom.inc' %]
index 549b563..509e5ba 100644 (file)
@@ -1,3 +1,4 @@
+[% USE Koha %]
 [% USE KohaDates %]
 [% USE ItemTypes %]
 [% USE Branches %]
@@ -53,10 +54,11 @@ $(document).ready(function() {
 [% IF ( run_report ) %] &rsaquo; Results[% END %]
 </div>
 
-<div id="doc2" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc2" class="yui-t7">[% END %]
 
    <div id="bd">
        <div id="yui-main">
+        [% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
        <div class="yui-g">
 
 <h1>Holds queue</h1>
@@ -226,5 +228,11 @@ $(document).ready(function() {
 
 </div>
 </div>
+[% IF Koha.Preference('CircSidebar') %]
+</div>
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
 </div>
 [% INCLUDE 'intranet-bottom.inc' %]
index 4c242af..80af602 100644 (file)
@@ -1,3 +1,4 @@
+[% USE Koha %]
 [% USE KohaDates %]
 [% USE Branches %]
 [% INCLUDE 'doc-head-open.inc' %]
 &rsaquo; <a href="/cgi-bin/koha/circ/waitingreserves.pl">Holds awaiting pickup</a>
 </div>
 
-<div id="doc3" class="yui-t7">
+[% IF Koha.Preference('CircSidebar') %]<div id="doc3" class="yui-t2">[% ELSE %]<div id="doc" class="yui-t7">[% END %]
 
    <div id="bd">
     <div id="yui-main">
+    [% IF Koha.Preference('CircSidebar') %]<div class="yui-b">[% END %]
     <div class="yui-g">
 
         <h2>Holds awaiting pickup for your library on: [% show_date | $KohaDates %]
 
 </div>
 </div>
+[% IF Koha.Preference('CircSidebar') %]
+</div>
+<div class="yui-b noprint">
+    [% INCLUDE 'circ-nav.inc' %]
+</div>
+[% END %]
 </div>
 [% INCLUDE 'intranet-bottom.inc' %]