|
Lines 56-61
our ( $template, $loggedinuser, $cookie ) = get_template_and_user(
Link Here
|
| 56 |
); |
56 |
); |
| 57 |
|
57 |
|
| 58 |
my @names = $input->param; |
58 |
my @names = $input->param; |
|
|
59 |
warn "NAMES: " . Data::Dumper::Dumper( \@names ); |
| 59 |
|
60 |
|
| 60 |
our $borrowernumber = $input->param('borrowernumber'); |
61 |
our $borrowernumber = $input->param('borrowernumber'); |
| 61 |
if ( !$borrowernumber ) { |
62 |
if ( !$borrowernumber ) { |
|
Lines 170-176
sub redirect_to_paycollect {
Link Here
|
| 170 |
$redirect .= get_for_redirect( 'amount', "amount$line_no", 1 ); |
171 |
$redirect .= get_for_redirect( 'amount', "amount$line_no", 1 ); |
| 171 |
$redirect .= |
172 |
$redirect .= |
| 172 |
get_for_redirect( 'amountoutstanding', "amountoutstanding$line_no", 1 ); |
173 |
get_for_redirect( 'amountoutstanding', "amountoutstanding$line_no", 1 ); |
| 173 |
$redirect .= get_for_redirect( 'accountno', "accountno$line_no", 0 ); |
|
|
| 174 |
$redirect .= get_for_redirect( 'title', "title$line_no", 0 ); |
174 |
$redirect .= get_for_redirect( 'title', "title$line_no", 0 ); |
| 175 |
$redirect .= get_for_redirect( 'itemnumber', "itemnumber$line_no", 0 ); |
175 |
$redirect .= get_for_redirect( 'itemnumber', "itemnumber$line_no", 0 ); |
| 176 |
$redirect .= get_for_redirect( 'notify_id', "notify_id$line_no", 0 ); |
176 |
$redirect .= get_for_redirect( 'notify_id', "notify_id$line_no", 0 ); |
|
Lines 184-190
sub redirect_to_paycollect {
Link Here
|
| 184 |
|
184 |
|
| 185 |
sub writeoff_all { |
185 |
sub writeoff_all { |
| 186 |
my @params = @_; |
186 |
my @params = @_; |
| 187 |
my @wo_lines = grep { /^accountno\d+$/ } @params; |
187 |
my @wo_lines = grep { /^accountlines_id\d+$/ } @params; |
| 188 |
for (@wo_lines) { |
188 |
for (@wo_lines) { |
| 189 |
if (/(\d+)/) { |
189 |
if (/(\d+)/) { |
| 190 |
my $value = $1; |
190 |
my $value = $1; |
|
Lines 193-199
sub writeoff_all {
Link Here
|
| 193 |
# my $borrowernum = $input->param("borrowernumber$value"); |
193 |
# my $borrowernum = $input->param("borrowernumber$value"); |
| 194 |
my $itemno = $input->param("itemnumber$value"); |
194 |
my $itemno = $input->param("itemnumber$value"); |
| 195 |
my $amount = $input->param("amountoutstanding$value"); |
195 |
my $amount = $input->param("amountoutstanding$value"); |
| 196 |
my $accountno = $input->param("accountno$value"); |
|
|
| 197 |
my $accountlines_id = $input->param("accountlines_id$value"); |
196 |
my $accountlines_id = $input->param("accountlines_id$value"); |
| 198 |
my $payment_note = $input->param("payment_note_$value"); |
197 |
my $payment_note = $input->param("payment_note_$value"); |
| 199 |
WriteOffFee( $borrowernumber, $accountlines_id, $itemno, $accounttype, $amount, $branch, $payment_note ); |
198 |
WriteOffFee( $borrowernumber, $accountlines_id, $itemno, $accounttype, $amount, $branch, $payment_note ); |
|
Lines 250-256
sub payselected {
Link Here
|
| 250 |
foreach (@params) { |
249 |
foreach (@params) { |
| 251 |
if (/^incl_par_(\d+)$/) { |
250 |
if (/^incl_par_(\d+)$/) { |
| 252 |
my $index = $1; |
251 |
my $index = $1; |
| 253 |
push @lines_to_pay, $input->param("accountno$index"); |
252 |
push @lines_to_pay, $input->param("accountlines_id$index"); |
| 254 |
$amt += $input->param("amountoutstanding$index"); |
253 |
$amt += $input->param("amountoutstanding$index"); |
| 255 |
} |
254 |
} |
| 256 |
} |
255 |
} |
| 257 |
- |
|
|