X-Git-Url: http://wagnertech.de/git?p=kivitendo-erp.git;a=blobdiff_plain;f=SL%2FController%2FFinancialControllingReport.pm;fp=SL%2FController%2FFinancialControllingReport.pm;h=f4f09ff0999af143a853193ab759c40a2c53662a;hp=125a8a8559561d24bec5239c8b74522cd8815736;hb=53593baa211863fbf66540cf1bcc36c8fb37257f;hpb=deb4d2dbb676d7d6f69dfe7815d6e0cb09bd4a44 diff --git a/SL/Controller/FinancialControllingReport.pm b/SL/Controller/FinancialControllingReport.pm index 125a8a855..f4f09ff09 100644 --- a/SL/Controller/FinancialControllingReport.pm +++ b/SL/Controller/FinancialControllingReport.pm @@ -37,6 +37,7 @@ sub action_list { $self->calculate_data; + $self->setup_list_action_bar; $self->list_objects; } @@ -243,6 +244,7 @@ sub init_models { query => [ SL::DB::Manager::Order->type_filter('sales_order'), '!closed' => 1, + (salesman_id => SL::DB::Manager::Employee->current->id) x !$::auth->assert('sales_all_edit', 1), or => [ globalproject_id => undef, and => [ @@ -276,7 +278,11 @@ sub link_to { my $type = $object->type; my $id = $object->id; - return "oe.pl?action=$action&type=$type&vc=customer&id=$id"; + if ($::instance_conf->get_feature_experimental_order) { + return "controller.pl?action=Order/$action&type=$type&id=$id"; + } else { + return "oe.pl?action=$action&type=$type&vc=customer&id=$id"; + } } if ($object->isa('SL::DB::Customer')) { my $id = $object->id; @@ -288,4 +294,18 @@ sub link_to { } } +sub setup_list_action_bar { + my ($self, %params) = @_; + + for my $bar ($::request->layout->get('actionbar')) { + $bar->add( + action => [ + t8('Update'), + submit => [ '#filter_form', { action => 'FinancialControllingReport/list' } ], + accesskey => 'enter', + ], + ); + } +} + 1;