projects
/
kivitendo-erp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of vc.linet-services.de:public/lx-office-erp
[kivitendo-erp.git]
/
bin
/
mozilla
/
projects.pl
diff --git
a/bin/mozilla/projects.pl
b/bin/mozilla/projects.pl
index
16d5e45
..
bda1c6d
100644
(file)
--- a/
bin/mozilla/projects.pl
+++ b/
bin/mozilla/projects.pl
@@
-92,7
+92,7
@@
sub search {
$form->{CUSTOM_VARIABLES_INCLUSION_CODE}) = CVar->render_search_options('variables' => $form->{CUSTOM_VARIABLES},
'include_prefix' => 'l_',
'include_value' => 'Y');
$form->{CUSTOM_VARIABLES_INCLUSION_CODE}) = CVar->render_search_options('variables' => $form->{CUSTOM_VARIABLES},
'include_prefix' => 'l_',
'include_value' => 'Y');
- $
form->{fokus} = 'getElementById("projectnumber")'
;
+ $
::request->{layout}->focus('#projectnumber')
;
$form->header();
print $form->parse_html_template('projects/search');
$form->header();
print $form->parse_html_template('projects/search');
@@
-119,10
+119,9
@@
sub project_report {
my $report = SL::ReportGenerator->new(\%myconfig, $form);
my @columns = qw(projectnumber description active);
my $report = SL::ReportGenerator->new(\%myconfig, $form);
my @columns = qw(projectnumber description active);
- my @hidden_vars = ('filter');
- my $href = build_std_url('action=project_report', @hidden_vars);
my @includeable_custom_variables = grep { $_->{includeable} } @{ $cvar_configs };
my @includeable_custom_variables = grep { $_->{includeable} } @{ $cvar_configs };
+ my @searchable_custom_variables = grep { $_->{searchable} } @{ $cvar_configs };
my %column_defs_cvars = ();
foreach (@includeable_custom_variables) {
$column_defs_cvars{"cvar_$_->{name}"} = {
my %column_defs_cvars = ();
foreach (@includeable_custom_variables) {
$column_defs_cvars{"cvar_$_->{name}"} = {
@@
-133,6
+132,15
@@
sub project_report {
push @columns, map { "cvar_$_->{name}" } @includeable_custom_variables;
push @columns, map { "cvar_$_->{name}" } @includeable_custom_variables;
+
+ my @hidden_vars = (
+ 'filter',
+ map({ ('cvar_'. $_->{name} , 'l_cvar_'. $_->{name}) } @includeable_custom_variables),
+ map({'cvar_'. $_->{name} .'_qtyop'} grep({$_->{type} eq 'number'} @searchable_custom_variables)),
+ );
+ my $href = build_std_url('action=project_report', @hidden_vars);
+
+
my %column_defs = (
'projectnumber' => { 'text' => $locale->text('Number'), },
'description' => { 'text' => $locale->text('Description'), },
my %column_defs = (
'projectnumber' => { 'text' => $locale->text('Number'), },
'description' => { 'text' => $locale->text('Description'), },
@@
-150,6
+158,13
@@
sub project_report {
$report->set_export_options('project_report', @hidden_vars, 'sort');
$report->set_export_options('project_report', @hidden_vars, 'sort');
+ CVar->add_custom_variables_to_report('module' => 'Project',
+ 'trans_id_field' => 'id',
+ 'configs' => $cvar_configs,
+ 'column_defs' => \%column_defs,
+ 'data' => $form->{project_list},
+ );
+
$report->set_sort_indicator($form->{sort}, 1);
my @options;
$report->set_sort_indicator($form->{sort}, 1);
my @options;