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

(-)a/C4/ILSDI/Services.pm (-6 / +7 lines)
Lines 445-456 sub GetPatronInfo { Link Here
445
445
446
    # Issues management
446
    # Issues management
447
    if ( $cgi->param('show_loans') && $cgi->param('show_loans') eq "1" ) {
447
    if ( $cgi->param('show_loans') && $cgi->param('show_loans') eq "1" ) {
448
        my $issues = GetPendingIssues($borrowernumber);
448
        my $pending_checkouts = $patron->pending_checkouts;
449
        foreach my $issue ( @$issues ){
449
        my @checkouts;
450
            $issue->{'issuedate'} = $issue->{'issuedate'}->strftime('%Y-%m-%d %H:%M');
450
        while ( my $c = $pending_checkouts->next ) {
451
            $issue->{'date_due'} = $issue->{'date_due'}->strftime('%Y-%m-%d %H:%M');
451
            # FIXME We should only retrieve what is needed in the template
452
            my $issue = $c->unblessed_all_relateds;
453
            push @checkouts, $issue
452
        }
454
        }
453
        $borrower->{'loans'}->{'loan'} = $issues;
455
        $borrower->{'loans'}->{'loan'} = \@checkouts;
454
    }
456
    }
455
457
456
    if ( $cgi->param('show_attributes') eq "1" ) {
458
    if ( $cgi->param('show_attributes') eq "1" ) {
457
- 

Return to bug 19935