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

(-)a/C4/Circulation.pm (-3 / +5 lines)
Lines 1525-1530 patron who last borrowed the book. Link Here
1525
1525
1526
sub AddReturn {
1526
sub AddReturn {
1527
    my ( $barcode, $branch, $exemptfine, $dropbox ) = @_;
1527
    my ( $barcode, $branch, $exemptfine, $dropbox ) = @_;
1528
1528
    if ($branch and not GetBranchDetail($branch)) {
1529
    if ($branch and not GetBranchDetail($branch)) {
1529
        warn "AddReturn error: branch '$branch' not found.  Reverting to " . C4::Context->userenv->{'branch'};
1530
        warn "AddReturn error: branch '$branch' not found.  Reverting to " . C4::Context->userenv->{'branch'};
1530
        undef $branch;
1531
        undef $branch;
Lines 1757-1762 routine in C<C4::Accounts>. Link Here
1757
1758
1758
sub MarkIssueReturned {
1759
sub MarkIssueReturned {
1759
    my ( $borrowernumber, $itemnumber, $dropbox_branch, $returndate, $privacy ) = @_;
1760
    my ( $borrowernumber, $itemnumber, $dropbox_branch, $returndate, $privacy ) = @_;
1761
1760
    my $dbh   = C4::Context->dbh;
1762
    my $dbh   = C4::Context->dbh;
1761
    my $query = 'UPDATE issues SET returndate=';
1763
    my $query = 'UPDATE issues SET returndate=';
1762
    my @bind;
1764
    my @bind;
Lines 3098-3109 sub LostItem{ Link Here
3098
3100
3099
    # if a borrower lost the item, add a replacement cost to the their record
3101
    # if a borrower lost the item, add a replacement cost to the their record
3100
    if ( my $borrowernumber = $issues->{borrowernumber} ){
3102
    if ( my $borrowernumber = $issues->{borrowernumber} ){
3101
3103
        my $borrower = C4::Members::GetMemberDetails( $borrowernumber );
3104
        
3102
        C4::Accounts::chargelostitem($borrowernumber, $itemnumber, $issues->{'replacementprice'}, "Lost Item $issues->{'title'} $issues->{'barcode'}")
3105
        C4::Accounts::chargelostitem($borrowernumber, $itemnumber, $issues->{'replacementprice'}, "Lost Item $issues->{'title'} $issues->{'barcode'}")
3103
          if $charge_fee;
3106
          if $charge_fee;
3104
        #FIXME : Should probably have a way to distinguish this from an item that really was returned.
3107
        #FIXME : Should probably have a way to distinguish this from an item that really was returned.
3105
        #warn " $issues->{'borrowernumber'}  /  $itemnumber ";
3108
        #warn " $issues->{'borrowernumber'}  /  $itemnumber ";
3106
        MarkIssueReturned($borrowernumber,$itemnumber) if $mark_returned;
3109
        MarkIssueReturned($borrowernumber,$itemnumber,undef,undef,$borrower->{'privacy'}) if $mark_returned;
3107
    }
3110
    }
3108
}
3111
}
3109
3112
3110
- 

Return to bug 8005