From 185d7c5bea8e3b9098d81bf98a3da5c23db8fd84 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Tue, 20 Feb 2007 09:11:32 +0000 Subject: [PATCH] =?utf8?q?Berichte=20->=20GuV=20und=20BWA:=20Projektauswah?= =?utf8?q?l=20als=20Drop-Down-Box.=20Bei=20BWA=20erscheint=20aber=20noch?= =?utf8?q?=20ein=20SQL-Fehler,=20wenn=20ein=20Projekt=20ausgew=C3=A4hlt=20?= =?utf8?q?wird.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- bin/mozilla/rp.pl | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/bin/mozilla/rp.pl b/bin/mozilla/rp.pl index fef3355b5..5cdeaa510 100644 --- a/bin/mozilla/rp.pl +++ b/bin/mozilla/rp.pl @@ -36,6 +36,7 @@ #====================================================================== require "$form->{path}/arap.pl"; +require "bin/mozilla/common.pl"; use SL::PE; use SL::RP; @@ -130,6 +131,21 @@ sub report { | if $form->{selectdepartment}; + $form->get_lists("projects" => { "key" => "ALL_PROJECTS", + "all" => 1 }); + + my %project_labels = (); + my @project_values = (""); + foreach my $item (@{ $form->{"ALL_PROJECTS"} }) { + push(@project_values, $item->{"id"}); + $project_labels{$item->{"id"}} = $item->{"projectnumber"}; + } + + my $projectnumber = + NTI($cgi->popup_menu('-name' => "project_id", + '-values' => \@project_values, + '-labels' => \%project_labels)); + # use JavaScript Calendar or not $form->{jsscript} = $jscalendar; $jsscript = ""; @@ -280,7 +296,7 @@ $jsscript print qq| | . $locale->text('Project') . qq| - + $projectnumber @@ -390,7 +406,7 @@ $jsscript print qq| | . $locale->text('Project') . qq| - + $projectnumber @@ -1062,10 +1078,6 @@ sub generate_income_statement { $form->{endbold} = ""; $form->{br} = "
"; - &get_project(generate_income_statement); - - $form->{projectnumber} = $form->{projectnumber_1}; - if ($form->{reporttype} eq "custom") { #forgotten the year --> thisyear @@ -2714,8 +2726,6 @@ sub generate_bwa { $form->{endbold} = ""; $form->{br} = "
"; - # &get_project(generate_bwa); - if ($form->{reporttype} eq "custom") { #forgotten the year --> thisyear -- 2.20.1