X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fgl.pl;h=625490dc86958b6eb7b0eb393ef20dda90d6a692;hb=388a2ff5471adc27084f77e60fe154f25790dc9e;hp=50f209e5b44847af10a749a8e6a3a88df245dfd0;hpb=b5c3b69626032bd48dfdce13d9795acf2eff89fd;p=kivitendo-erp.git diff --git a/bin/mozilla/gl.pl b/bin/mozilla/gl.pl index 50f209e5b..625490dc8 100644 --- a/bin/mozilla/gl.pl +++ b/bin/mozilla/gl.pl @@ -218,7 +218,7 @@ sub search { my $form = $main::form; my %myconfig = %main::myconfig; my $locale = $main::locale; - my $cgi = $main::cgi; + my $cgi = $::request->{cgi}; $form->{title} = $locale->text('Journal'); @@ -234,7 +234,8 @@ sub search { } (@{ $form->{all_departments} || [] }); } - my $department = qq| + my $department; + $department = qq| | . $locale->text('Department') . qq| @@ -342,8 +343,6 @@ sub search { | . $locale->text('Project Number') . qq| $projectnumber - - | . $locale->text('From') . qq| | . $locale->text('Employee') . qq| $employeenumber @@ -509,7 +508,7 @@ sub generate_report { my @columns = qw( gldate transdate id reference description - notes source debit debit_accno + notes source debit debit_accno credit credit_accno debit_tax debit_tax_accno credit_tax credit_tax_accno projectnumbers balance employee ); @@ -863,7 +862,7 @@ sub display_rows { my $form = $main::form; my %myconfig = %main::myconfig; - my $cgi = $main::cgi; + my $cgi = $::request->{cgi}; $form->{debit_1} = 0 if !$form->{"debit_1"}; $form->{totaldebit} = 0; @@ -1019,7 +1018,7 @@ sub display_rows { my $projectnumber_hidden = qq| |; - my $copy2credit = 'onkeyup="copy_debit_to_credit()"' if $i == 1; + my $copy2credit = $i == 1 ? 'onkeyup="copy_debit_to_credit()"' : ''; print qq| $accno @@ -1081,10 +1080,9 @@ sub form_header { $form->{title} = $locale->text("$title General Ledger Transaction"); my $readonly = ($form->{id}) ? "readonly" : ""; - my $show_details_checked = "checked" if $form->{show_details}; - - my $ob_transaction_checked = "checked" if $form->{ob_transaction}; - my $cb_transaction_checked = "checked" if $form->{cb_transaction}; + my $show_details_checked = $form->{show_details} ? "checked" : ''; + my $ob_transaction_checked = $form->{ob_transaction} ? "checked" : ''; + my $cb_transaction_checked = $form->{cb_transaction} ? "checked" : ''; # $locale->text('Add General Ledger Transaction') # $locale->text('Edit General Ledger Transaction') @@ -1349,7 +1347,7 @@ sub form_footer { my $form = $main::form; my %myconfig = %main::myconfig; my $locale = $main::locale; - my $cgi = $main::cgi; + my $cgi = $::request->{cgi}; my $follow_ups_block; if ($form->{id}) { @@ -1412,7 +1410,7 @@ $follow_ups_block } else { if ($form->{draft_id}) { - my $remove_draft_checked = 'checked' if ($form->{remove_draft}); + my $remove_draft_checked = $form->{remove_draft} ? 'checked' : ''; print qq|

\n| . qq| | . qq| \n|