#
#######################################################################
+use SL::IC;
+
# any custom scripts for this one
if (-f "$form->{path}/custom_io.pl") {
eval { require "$form->{path}/custom_io.pl"; };
sub display_form {
$lxdebug->enter_sub();
+
+ relink_accounts();
+
$form->language_payment(\%myconfig);
# if we have a display_form
$lxdebug->leave_sub();
}
+sub relink_accounts {
+ $lxdebug->enter_sub();
+
+ $form->{"taxaccounts"} =~ s/\s*$//;
+ $form->{"taxaccounts"} =~ s/^\s*//;
+ foreach my $accno (split(/\s*/, $form->{"taxaccounts"})) {
+ map({ delete($form->{"${accno}_${_}"}); } qw(rate description taxnumber));
+ }
+ $form->{"taxaccounts"} = "";
+
+ for ($i = 1; $i <= $form->{"rowcount"}; $i++) {
+ if ($form->{"id_$i"}) {
+ IC->retrieve_taxaccounts(\%myconfig, $form, $form->{"id_$i"}, $i, 1);
+ }
+ }
+
+ $lxdebug->leave_sub();
+}