koha-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Koha-cvs] koha/circ returns.pl [dev_week]


From: Mason James
Subject: [Koha-cvs] koha/circ returns.pl [dev_week]
Date: Fri, 11 May 2007 03:58:21 +0000

CVSROOT:        /sources/koha
Module name:    koha
Branch:         dev_week
Changes by:     Mason James <sushi>     07/05/11 03:58:21

Modified files:
        circ           : returns.pl 

Log message:
        wrapped CCFLS specific code in 'IF' statements, PrintR.pm and 
RotatingCollections.pm need commiting to CVS too :)

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/circ/returns.pl?cvsroot=koha&only_with_tag=dev_week&r1=1.37.2.6.2.8&r2=1.37.2.6.2.9

Patches:
Index: returns.pl
===================================================================
RCS file: /sources/koha/koha/circ/returns.pl,v
retrieving revision 1.37.2.6.2.8
retrieving revision 1.37.2.6.2.9
diff -u -b -r1.37.2.6.2.8 -r1.37.2.6.2.9
--- returns.pl  7 May 2007 13:53:01 -0000       1.37.2.6.2.8
+++ returns.pl  11 May 2007 03:58:21 -0000      1.37.2.6.2.9
@@ -23,8 +23,6 @@
 # Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
 # Suite 330, Boston, MA  02111-1307 USA
 
-use PrintR;
-
 use strict;
 
 use CGI;
@@ -42,6 +40,16 @@
 use C4::Koha;
 use C4::RotatingCollections;
 
+#wrapping PrintR.pm and C4::RotatingCollections call for CCFS in an 'if'
+# both files need to be commited to CVS :)
+my library_name = C4::Context->preference("LibraryName");
+
+if ( $library_name =~ /CCFLS/ ) {
+    use PrintR; 
+    use C4::RotatingCollections;
+}
+
+
 my $query = new CGI;
 
 #getting the template
@@ -161,7 +169,9 @@
 if ($barcode) {
 
     #CCFLS ONLY
+    if ( $library_name =~ /CCFLS/ ) {
     system "php /usr/local/koha/intranet/htdocs/ccflsFines/createFine.php 
$barcode";
+    }
 
     # decode cuecat
     $barcode = cuecatbarcodedecode($barcode);
@@ -500,9 +510,10 @@
        IntranetNav => C4::Context->preference("IntranetNav"),
 );
 
+if ( $library_name =~ /CCFLS/ ) {
 ## Check to see if returned item is a rotating collection item returned to the 
wrong branch
-my $itemnumber = getItemnumberByBarcode( $query->param('barcode') );
-if ( $itemnumber ) {
+    my $itemnumber = getItemnumberByBarcode( $query->param('barcode') );
+    if ( $itemnumber ) {
   my ( $holdingBranch, $collectionBranch ) = GetCollectionItemBranches( 
$itemnumber );
   if ( ! ( $holdingBranch eq $collectionBranch ) ) {
     $template->param(
@@ -510,6 +521,7 @@
       collectionBranch => $collectionBranch,
     );
   }
+    }
 }
 
 # actually print the page!




reply via email to

[Prev in Thread] Current Thread [Next in Thread]