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

(-)a/C4/Circulation.pm (-2 / +2 lines)
Lines 1678-1684 patron who last borrowed the book. Link Here
1678
=cut
1678
=cut
1679
1679
1680
sub AddReturn {
1680
sub AddReturn {
1681
    my ( $barcode, $branch, $exemptfine, $dropbox ) = @_;
1681
    my ( $barcode, $branch, $exemptfine, $dropbox, $return_date) = @_;
1682
1682
1683
    if ($branch and not GetBranchDetail($branch)) {
1683
    if ($branch and not GetBranchDetail($branch)) {
1684
        warn "AddReturn error: branch '$branch' not found.  Reverting to " . C4::Context->userenv->{'branch'};
1684
        warn "AddReturn error: branch '$branch' not found.  Reverting to " . C4::Context->userenv->{'branch'};
Lines 1775-1781 sub AddReturn { Link Here
1775
              );
1775
              );
1776
        }
1776
        }
1777
            }
1777
            }
1778
            MarkIssueReturned($borrowernumber, $item->{'itemnumber'}, $circControlBranch, '', $borrower->{'privacy'});
1778
            MarkIssueReturned($borrowernumber, $item->{'itemnumber'}, $circControlBranch, $return_date, $borrower->{'privacy'});
1779
            $messages->{'WasReturned'} = 1;    # FIXME is the "= 1" right?  This could be the borrower hash.
1779
            $messages->{'WasReturned'} = 1;    # FIXME is the "= 1" right?  This could be the borrower hash.
1780
        }
1780
        }
1781
1781
(-)a/C4/SIP/ILS/Transaction/Checkin.pm (-6 / +4 lines)
Lines 46-58 sub new { Link Here
46
46
47
sub do_checkin {
47
sub do_checkin {
48
    my $self = shift;
48
    my $self = shift;
49
    my $branch = shift;
49
    my $branch = shift || 'SIP2';
50
    if (!$branch) {
50
    my $return_date = shift;
51
        $branch = 'SIP2';
51
52
    }
53
    my $barcode = $self->{item}->id;
52
    my $barcode = $self->{item}->id;
54
    $debug and warn "do_checkin() calling AddReturn($barcode, $branch)";
53
    $debug and warn "do_checkin() calling AddReturn($barcode, $branch)";
55
    my ($return, $messages, $iteminformation, $borrower) = AddReturn($barcode, $branch);
54
    my ($return, $messages, $iteminformation, $borrower) = AddReturn($barcode, $branch, undef, undef, $return_date);
56
    $self->alert(!$return);
55
    $self->alert(!$return);
57
    # ignoring messages: NotIssued, IsPermanent, WasLost, WasTransfered
56
    # ignoring messages: NotIssued, IsPermanent, WasLost, WasTransfered
58
57
59
- 

Return to bug 8769