fix typos on syspref
authorRyan Higgins <rch@liblime.com>
Wed, 7 Nov 2007 21:46:17 +0000 (15:46 -0600)
committerJoshua Ferraro <jmf@liblime.com>
Thu, 8 Nov 2007 23:14:32 +0000 (17:14 -0600)
Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
C4/Biblio.pm
C4/Overdues.pm

index fc0f8e7..e9067bc 100644 (file)
@@ -258,7 +258,7 @@ sub AddItem {
     $sth =
       $dbh->prepare(
         "SELECT notforloan FROM itemtypes WHERE itemtype=?");
-    $sth->execute( C4::Context->preference('item-level_itype') ? $item->{'ccode'} : $itemtype );
+    $sth->execute( C4::Context->preference('item-level_itypes') ? $item->{'ccode'} : $itemtype );
     my $notforloan = $sth->fetchrow;
     ##Change the notforloan field if $notforloan found
     if ( $notforloan > 0 ) {
@@ -652,7 +652,7 @@ sub GetBiblioData {
     my ( $bibnum ) = @_;
     my $dbh = C4::Context->dbh;
 
-    my $query =  C4::Context->preference('item-level_itype')  
+    my $query =  C4::Context->preference('item-level_itypes')  
                ? " SELECT * , biblioitems.notes AS bnotes, itemtypes.notforloan as bi_notforloan, biblio.notes
                FROM biblio
             LEFT JOIN biblioitems ON biblio.biblionumber = biblioitems.biblionumber
@@ -732,7 +732,7 @@ sub GetItemsInfo {
                  FROM items 
                  LEFT JOIN biblio ON biblio.biblionumber = items.biblionumber
                  LEFT JOIN biblioitems ON biblioitems.biblioitemnumber = items.biblioitemnumber";
-       $query .=  (C4::Context->preference('item-level_itype')) ?
+       $query .=  (C4::Context->preference('item-level_itypes')) ?
                                         " LEFT JOIN itemtypes on items.ccode = itemtypes.itemtype "
                                        : " LEFT JOIN itemtypes on biblioitems.itemtype = itemtypes.itemtype ";
        $query .= "WHERE items.biblionumber = ? ORDER BY items.dateaccessioned desc" ;
@@ -1142,7 +1142,7 @@ sub GetBiblioItemData {
     my $dbh       = C4::Context->dbh;
        my $query = "SELECT *,biblioitems.notes AS bnotes
                FROM biblio, biblioitems ";
-       if(C4::Context->preference('item-level_itype')) { 
+       if(C4::Context->preference('item-level_itypes')) { 
                $query .= "LEFT JOIN itemtypes on biblioitems.itemtype=itemtypes.itemtype ";
        }        
        $query .= " WHERE biblio.biblionumber = biblioitems.biblionumber 
index fb9305b..bad617e 100644 (file)
@@ -115,8 +115,7 @@ Koha database.
 #'
 sub Getoverdues {
     my $dbh = C4::Context->dbh;
-       my $itype_q = (C4::context->preference('item-level_itype')) ? " items.ccode as itemtype "
-    my $sth =  (C4::context->preference('item-level_itype')) ? 
+    my $sth =  (C4::context->preference('item-level_itypes')) ? 
                                $dbh->prepare(
                                "SELECT issues.*,items.ccode as itemtype FROM issues 
                        LEFT JOIN items USING (itemnumber)
@@ -1150,7 +1149,7 @@ display is filtered by branch
 
 sub GetOverduesForBranch {
     my ( $branch, $location) = @_;
-       my $itype_link =  (C4::context->preference('item-level_itype')) ?  " items.ccode " :  " biblioitems.itemtype ";
+       my $itype_link =  (C4::context->preference('item-level_itypes')) ?  " items.ccode " :  " biblioitems.itemtype ";
     if ( not $location ) {
         my $dbh = C4::Context->dbh;
         my $sth = $dbh->prepare("