Lines 55-60
my $branch = C4::Context->userenv->{'branch'};
Link Here
|
55 |
|
55 |
|
56 |
my ( $total_due, $accts, $numaccts ) = GetMemberAccountRecords($borrowernumber); |
56 |
my ( $total_due, $accts, $numaccts ) = GetMemberAccountRecords($borrowernumber); |
57 |
my $total_paid = $input->param('paid'); |
57 |
my $total_paid = $input->param('paid'); |
|
|
58 |
my $paymentmode = $input->param('paymentmode'); |
58 |
|
59 |
|
59 |
my $individual = $input->param('pay_individual'); |
60 |
my $individual = $input->param('pay_individual'); |
60 |
my $writeoff = $input->param('writeoff_individual'); |
61 |
my $writeoff = $input->param('writeoff_individual'); |
Lines 117-123
if ( $total_paid and $total_paid ne '0.00' ) {
Link Here
|
117 |
lines => [$line], |
118 |
lines => [$line], |
118 |
amount => $total_paid, |
119 |
amount => $total_paid, |
119 |
library_id => $branch, |
120 |
library_id => $branch, |
120 |
note => $payment_note |
121 |
note => $payment_note, |
|
|
122 |
paymentmode => $paymentmode, |
121 |
} |
123 |
} |
122 |
); |
124 |
); |
123 |
print $input->redirect( |
125 |
print $input->redirect( |
Lines 129-135
if ( $total_paid and $total_paid ne '0.00' ) {
Link Here
|
129 |
} |
131 |
} |
130 |
my @acc = split /,/, $select; |
132 |
my @acc = split /,/, $select; |
131 |
my $note = $input->param('selected_accts_notes'); |
133 |
my $note = $input->param('selected_accts_notes'); |
132 |
|
|
|
133 |
my @lines = Koha::Account::Lines->search( |
134 |
my @lines = Koha::Account::Lines->search( |
134 |
{ |
135 |
{ |
135 |
borrowernumber => $borrowernumber, |
136 |
borrowernumber => $borrowernumber, |
Lines 148-160
if ( $total_paid and $total_paid ne '0.00' ) {
Link Here
|
148 |
amount => $total_paid, |
149 |
amount => $total_paid, |
149 |
lines => \@lines, |
150 |
lines => \@lines, |
150 |
note => $note, |
151 |
note => $note, |
|
|
152 |
paymentmode => $paymentmode, |
151 |
} |
153 |
} |
152 |
); |
154 |
); |
153 |
} |
155 |
} |
154 |
else { |
156 |
else { |
155 |
my $note = $input->param('selected_accts_notes'); |
157 |
my $note = $input->param('selected_accts_notes'); |
156 |
Koha::Account->new( { patron_id => $borrowernumber } ) |
158 |
Koha::Account->new( { patron_id => $borrowernumber } ) |
157 |
->pay( { amount => $total_paid, note => $note } ); |
159 |
->pay( { amount => $total_paid, note => $note, paymentmode => $paymentmode } ); |
158 |
} |
160 |
} |
159 |
|
161 |
|
160 |
print $input->redirect( |
162 |
print $input->redirect( |
161 |
- |
|
|