View | Details | Raw Unified | Return to bug 2505
Collapse All | Expand All

(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tmpl (-1 / +1 lines)
Lines 61-67 TMPL_ELSE -->Title<!-- /TMPL_UNLESS --></th> Link Here
61
                    <span class="item-details">
61
                    <span class="item-details">
62
                        <!-- TMPL_VAR NAME="author" -->
62
                        <!-- TMPL_VAR NAME="author" -->
63
                    </span></td>
63
                    </span></td>
64
<!-- TMPL_UNLESS NAME="item-level_itypes" --><td><!-- TMPL_IF NAME="imageurl" --><img src="<!-- TMPL_VAR NAME="imageurl" -->" title="<!-- TMPL_VAR name="description" -->" alt="<!-- TMPL_VAR NAME="description" -->" /><!-- /TMPL_IF --> <!-- TMPL_VAR name="description" --></td><!-- /TMPL_UNLESS -->
64
<!-- TMPL_UNLESS NAME="item-level_itypes" --><td><!-- TMPL_IF NAME="imageurl" --><img src="<!-- TMPL_VAR NAME="imageurl" -->" title="<!-- TMPL_VAR name="itypedescription" -->" alt="<!-- TMPL_VAR NAME="itypedescription" -->" /><!-- /TMPL_IF --> <!-- TMPL_VAR name="itypedescription" --></td><!-- /TMPL_UNLESS -->
65
<td><!-- TMPL_VAR NAME="itemcallnumber" --></td>
65
<td><!-- TMPL_VAR NAME="itemcallnumber" --></td>
66
<td><!-- TMPL_IF NAME="returndate" --><!-- TMPL_VAR NAME="returndate" --><!-- TMPL_ELSE --><em>(Checked out)</em><!-- /TMPL_IF --></td>
66
<td><!-- TMPL_IF NAME="returndate" --><!-- TMPL_VAR NAME="returndate" --><!-- TMPL_ELSE --><em>(Checked out)</em><!-- /TMPL_IF --></td>
67
</tr>
67
</tr>
(-)a/opac/opac-readingrecord.pl (-12 / +12 lines)
Lines 17-22 Link Here
17
17
18
18
19
use strict;
19
use strict;
20
use warnings;
20
21
21
use CGI;
22
use CGI;
22
23
Lines 48-69 $template->param($borr); Link Here
48
my $itemtypes = GetItemTypes();
49
my $itemtypes = GetItemTypes();
49
50
50
# get the record
51
# get the record
51
my $order  = $query->param('order');
52
my $order  = $query->param('order') || '';
52
my $order2 = $order;
53
if ( $order eq '' ) {
53
if ( $order2 eq '' ) {
54
    $order = "date_due desc";
54
    $order2 = "date_due desc";
55
    $template->param( orderbydate => 1 );
55
    $template->param( orderbydate => 1 );
56
}
56
}
57
57
58
if ( $order2 eq 'title' ) {
58
if ( $order eq 'title' ) {
59
    $template->param( orderbytitle => 1 );
59
    $template->param( orderbytitle => 1 );
60
}
60
}
61
61
62
if ( $order2 eq 'author' ) {
62
if ( $order eq 'author' ) {
63
    $template->param( orderbyauthor => 1 );
63
    $template->param( orderbyauthor => 1 );
64
}
64
}
65
65
66
my $limit = $query->param('limit');
66
my $limit = $query->param('limit') || 50;
67
if ( $limit eq 'full' ) {
67
if ( $limit eq 'full' ) {
68
    $limit = 0;
68
    $limit = 0;
69
}
69
}
Lines 71-79 else { Link Here
71
    $limit = 50;
71
    $limit = 50;
72
}
72
}
73
73
74
my ( $count, $issues ) = GetAllIssues( $borrowernumber, $order2, $limit );
74
my ( $count, $issues ) = GetAllIssues( $borrowernumber, $order, $limit );
75
75
76
my $borr = GetMemberDetails( $borrowernumber );
77
my @bordat;
76
my @bordat;
78
$bordat[0] = $borr;
77
$bordat[0] = $borr;
79
$template->param( BORROWER_INFO => \@bordat );
78
$template->param( BORROWER_INFO => \@bordat );
Lines 94-101 for ( my $i = 0 ; $i < $count ; $i++ ) { Link Here
94
    $line{returndate}     = format_date( $issues->[$i]->{'returndate'} );
93
    $line{returndate}     = format_date( $issues->[$i]->{'returndate'} );
95
    $line{volumeddesc}    = $issues->[$i]->{'volumeddesc'};
94
    $line{volumeddesc}    = $issues->[$i]->{'volumeddesc'};
96
    $line{counter}        = $i + 1;
95
    $line{counter}        = $i + 1;
97
    $line{'description'} = $itemtypes->{ $issues->[$i]->{'itemtype'} }->{'description'};
96
    if($issues->[$i]->{'itemtype'}) {
98
    $line{imageurl}       = getitemtypeimagelocation( 'opac', $itemtypes->{ $issues->[$i]->{'itemtype'}  }->{'imageurl'} );
97
        $line{'itypedescription'} = $itemtypes->{ $issues->[$i]->{'itemtype'} }->{'description'};
98
        $line{imageurl}       = getitemtypeimagelocation( 'opac', $itemtypes->{ $issues->[$i]->{'itemtype'}  }->{'imageurl'} );
99
    }
99
    push( @loop_reading, \%line );
100
    push( @loop_reading, \%line );
100
}
101
}
101
102
102
- 

Return to bug 2505