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

(-)a/opac/opac-account-pay-paypal-return.pl (-5 / +4 lines)
Lines 90-99 if ( $response->is_success ) { Link Here
90
    if ( $params->{ACK} eq "Success" ) {
90
    if ( $params->{ACK} eq "Success" ) {
91
        $amount = $params->{PAYMENTINFO_0_AMT};
91
        $amount = $params->{PAYMENTINFO_0_AMT};
92
92
93
        my $accountlines_rs = Koha::Database->new()->schema()->resultset('Accountline');
93
        my $account = Koha::Account->new( { patron_id => $borrowernumber } );
94
        foreach my $accountlines_id ( @accountlines ) {
94
        foreach my $accountlines_id (@accountlines) {
95
            my $accountline = $accountlines_rs->find( $accountlines_id );
95
            my $line = Koha::Account::Lines->find($accountlines_id);
96
            makepayment( $accountlines_id, $borrowernumber, undef, $accountline->amountoutstanding, undef, undef, 'PayPal' );
96
            $account->pay( { lines => [$line], note => 'PayPal' } );
97
        }
97
        }
98
    }
98
    }
99
    else {
99
    else {
100
- 

Return to bug 15907