Bug 20168: Compiled CSS - RTL files
[koha-ffzg.git] / catalogue / imageviewer.pl
index 8b734a4..ac7d320 100755 (executable)
@@ -26,7 +26,6 @@ use C4::Items;
 use C4::Output;
 use C4::Images;
 use C4::Search;
-use C4::Acquisition qw(GetOrdersByBiblionumber);
 
 use Koha::Biblios;
 use Koha::Patrons;
@@ -37,7 +36,6 @@ my ( $template, $borrowernumber, $cookie ) = get_template_and_user(
         template_name   => "catalogue/imageviewer.tt",
         query           => $query,
         type            => "intranet",
-        authnotrequired => 0,
         flagsrequired   => { catalogue => 1 },
     }
 );
@@ -48,15 +46,6 @@ my $biblio = Koha::Biblios->find( $biblionumber );
 my $itemcount = $biblio ? $biblio->items->count : 0;
 my @items = GetItemsInfo($biblionumber);
 
-my $norequests = 1;
-foreach my $item (@items) {
-
-    # can place holds defaults to yes
-    $norequests = 0
-      unless ( ( $item->{'notforloan_per_itemtype'} > 0 )
-        || ( $item->{'itemnotforloan'} > 0 ) );
-}
-
 if ( $query->cookie("holdfor") ) {
     my $holdfor_patron = Koha::Patrons->find( $query->cookie("holdfor") );
     $template->param(
@@ -83,38 +72,9 @@ if ( C4::Context->preference("LocalCoverImages") ) {
 }
 $template->{VARS}->{'count'}        = $itemcount;
 $template->{VARS}->{'biblionumber'} = $biblionumber;
-$template->{VARS}->{'norequests'}   = $norequests;
 $template->param(C4::Search::enabled_staff_search_views);
 $template->{VARS}->{'biblio'} = $biblio;
 
-my @allorders_using_biblio = GetOrdersByBiblionumber ($biblionumber);
-my @deletedorders_using_biblio;
-my @orders_using_biblio;
-my @baskets_orders;
-my @baskets_deletedorders;
-
-foreach my $myorder (@allorders_using_biblio) {
-    my $basket = $myorder->{'basketno'};
-    if ((defined $myorder->{'datecancellationprinted'}) and  ($myorder->{'datecancellationprinted'} ne '0000-00-00') ){
-        push @deletedorders_using_biblio, $myorder;
-        unless (grep(/^$basket$/, @baskets_deletedorders)){
-            push @baskets_deletedorders,$myorder->{'basketno'};
-        }
-    }
-    else {
-        push @orders_using_biblio, $myorder;
-        unless (grep(/^$basket$/, @baskets_orders)){
-            push @baskets_orders,$myorder->{'basketno'};
-            }
-    }
-}
-
-my $count_orders_using_biblio = scalar @orders_using_biblio ;
-$template->param (countorders => $count_orders_using_biblio);
-
-my $count_deletedorders_using_biblio = scalar @deletedorders_using_biblio ;
-$template->param (countdeletedorders => $count_deletedorders_using_biblio);
-
 my $hold_count = $biblio ? $biblio->holds->count : 0;
 $template->param( holdcount => $hold_count );