if ($item eq ''){
$form->{ACCOUNT_TAXKEYS}[$i]{select_tax} .= qq|<option value="" selected="selected">-\n|;
}
- elsif ( $item == $taxkey_used->{pos_ustva} ) {
+ elsif ( $item eq $taxkey_used->{pos_ustva} ) {
$form->{ACCOUNT_TAXKEYS}[$i]{select_tax} .= qq|<option value="$item" selected="selected">$item\n|;
}
else {
foreach $ca (@{ $form->{CA} }) {
- $ca->{debit} = " ";
- $ca->{credit} = " ";
+ $ca->{debit} = "";
+ $ca->{credit} = "";
if ($ca->{amount} > 0) {
- $ca->{credit} =
- $form->format_amount(\%myconfig, $ca->{amount}, 2, " ");
+ $ca->{credit} = $form->format_amount(\%myconfig, $ca->{amount}, 2);
}
if ($ca->{amount} < 0) {
- $ca->{debit} =
- $form->format_amount(\%myconfig, -1 * $ca->{amount}, 2, " ");
+ $ca->{debit} = $form->format_amount(\%myconfig, -1 * $ca->{amount}, 2);
}
$ca->{heading} = ( $ca->{charttype} eq 'H' ) ? 1:'';
$ca->{link_edit_account} =
."&password=$form->{password}&action=list_account_details&";
- my $pjx = new CGI::Ajax(
- 'list_account_details' => $list_account_details_url
- );
+ my $pjx = new CGI::Ajax('list_account_details' => $list_account_details_url);
# Eneable AJAX debuging
#$pjx->DEBUG(1);
#$pjx->JSDEBUG(1);
push(@ { $form->{AJAX} }, $pjx);
-
+
+ $form->{stylesheets} = "list_accounts.css";
+
$form->header;
};
# Ausgabe des Templates
- print($form->parse_html_template('am/list_accounts', $parameters_ref));
+ print($form->parse_html_template2('am/list_accounts', $parameters_ref));
$lxdebug->leave_sub();
<li>| . $locale->text("<%skonto_amount%> -- The deductible amount")
. qq|</li>
<li>| . $locale->text("<%total%> -- Amount payable")
+. qq|</li>
+ <li>| . $locale->text("<%total_wo_skonto%> -- Amount payable less discount")
. qq|</li>
<li>| . $locale->text("<%invtotal%> -- Invoice total")
+. qq|</li>
+ <li>| . $locale->text("<%invtotal_wo_skonto%> -- Invoice total less discount")
. qq|</li>
<li>| . $locale->text("<%currency%> -- The selected currency")
. qq|</li>
sub save_tax {
$lxdebug->enter_sub();
- $form->isblank("chart_id", $locale->text('Tax-O-Matic account missing!'));
$form->isblank("rate", $locale->text('Taxrate missing!'));
$form->isblank("taxdescription", $locale->text('Taxdescription missing!'));
$form->isblank("taxkey", $locale->text('Taxkey missing!'));
$form->{rate} = $form->parse_amount(\%myconfig, $form->{rate});
- if ( $form->{rate} <= 0 || $form->{rate} >= 100 ) {
+ if ( $form->{rate} < 0 || $form->{rate} >= 100 ) {
$form->error($locale->text('Tax Percent is a number between 0 and 100'));
}
- if ( $form->{rate} <= 0.99 && $form->{rate} >= 0 ) {
+ if ( $form->{rate} <= 0.99 && $form->{rate} > 0 ) {
$form->error($locale->text('Tax Percent is a number between 0 and 100'));
}