X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=bin%2Fmozilla%2Far.pl;h=80c87f966567e3150d2a627001db825d3792bcec;hb=59d76a094e83bec189313ca712d945a9594aeb55;hp=e69e13cbf32d3b69b93f3a94c101f148db9bb5c2;hpb=b21a00cf4c891da7bc99d7010a0584decd164906;p=kivitendo-erp.git
diff --git a/bin/mozilla/ar.pl b/bin/mozilla/ar.pl
index e69e13cbf..80c87f966 100644
--- a/bin/mozilla/ar.pl
+++ b/bin/mozilla/ar.pl
@@ -38,6 +38,7 @@ use SL::AR;
use SL::FU;
use SL::IS;
use SL::PE;
+use SL::DB::Default;
use SL::ReportGenerator;
require "bin/mozilla/arap.pl";
@@ -160,9 +161,6 @@ sub create_links {
$form->{oldcustomer} = "$form->{customer}--$form->{customer_id}";
$form->{rowcount} = 1;
- # notes
- $form->{notes} = $form->{intnotes} unless $form->{notes};
-
# currencies
$form->{defaultcurrency} = $form->get_default_currency(\%myconfig);
@@ -219,7 +217,6 @@ sub form_header {
my ($title, $readonly, $exchangerate, $rows);
my ($notes, $department, $customer, $employee, $amount, $project);
- my ($onload);
my ($ARselected);
@@ -252,7 +249,9 @@ sub form_header {
#/show history button js
$readonly = ($form->{id}) ? "readonly" : "";
- $form->{radier} = ($form->current_date(\%myconfig) eq $form->{gldate}) ? 1 : 0;
+ $form->{radier} = ($::instance_conf->get_ar_changeable == 2)
+ ? ($form->current_date(\%myconfig) eq $form->{gldate})
+ : ($::instance_conf->get_ar_changeable == 1);
$readonly = ($form->{radier}) ? "" : $readonly;
# set option selected
@@ -316,7 +315,7 @@ sub form_header {
$taxcharts{$item->{id}} = $item;
}
- $form->{fokus} = "arledger.customer";
+ $::request->{layout}->focus("#customer");
my $follow_up_vc = $form->{customer};
$follow_up_vc =~ s/--.*?//;
@@ -326,9 +325,6 @@ sub form_header {
qq|| .
qq||;
- $onload = qq|focus()|;
- $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
-
# $amount = $locale->text('Amount');
# $project = $locale->text('Project');
@@ -336,7 +332,7 @@ sub form_header {
for my $i (1 .. $form->{rowcount}) {
my $transaction = {
amount => $form->{"amount_$i"},
- tax => $form->{"tax$i"},
+ tax => $form->{"tax_$i"},
project_id => $form->{"project_id_$i"},
};
@@ -375,7 +371,7 @@ sub form_header {
. $cgi->hidden('-name' => "previous_AR_amount_$i",
'-default' => $selected_accno_full);
- $transaction->{tax} =
+ $transaction->{taxchart} =
NTI($cgi->popup_menu('-name' => "taxchart_$i",
'-id' => "taxchart_$i",
'-style' => 'width:200px',
@@ -425,8 +421,8 @@ sub form_header {
$payment->{changeable} =
- $::lx_office_conf{features}->{payments_changeable} == 0 ? !$payment->{acc_trans_id} # never
- : $::lx_office_conf{features}->{payments_changeable} == 2 ? $payment->{gldate} eq '' || $payment->{gldate} eq $now
+ SL::DB::Default->get->payments_changeable == 0 ? !$payment->{acc_trans_id} # never
+ : SL::DB::Default->get->payments_changeable == 2 ? $payment->{gldate} eq '' || $payment->{gldate} eq $now
: 1;
push @payments, $payment;
@@ -443,7 +439,6 @@ sub form_header {
project_labels => \%project_labels,
rows => $rows,
ARselected => $ARselected,
- onload => $onload,
title_str => $title,
follow_up_trans_info => $follow_up_trans_info,
});
@@ -529,17 +524,13 @@ $follow_ups_block
}
}
- if ($form->{menubar}) {
- require "bin/mozilla/menu.pl";
- &menubar;
- }
# button for saving history
if($form->{id} ne "") {
print qq| {id}); name=history id=history value=| . $locale->text('history') . qq|> |;
}
# /button for saving history
# mark_as_paid button
- if($form->{id} ne "") {
+ if(($form->{id} ne "") && $::instance_conf->get_ar_show_mark_as_paid) {
print qq||;
}
@@ -547,9 +538,6 @@ $follow_ups_block
print "
-
-