From 267374ef8d99b9b802be53d07330d2fcb1886284 Mon Sep 17 00:00:00 2001 From: Thomas Heck Date: Mon, 24 Jun 2013 10:40:44 +0200 Subject: [PATCH] SL::Controller::Customer entfernt --- SL/Controller/Customer.pm | 26 -------------------------- 1 file changed, 26 deletions(-) delete mode 100644 SL/Controller/Customer.pm diff --git a/SL/Controller/Customer.pm b/SL/Controller/Customer.pm deleted file mode 100644 index 823af2e59..000000000 --- a/SL/Controller/Customer.pm +++ /dev/null @@ -1,26 +0,0 @@ -package SL::Controller::Customer; - -use strict; -use parent qw(SL::Controller::Base); - -use SL::DB::Customer; - -# safety -__PACKAGE__->run_before(sub { $::auth->assert('customer_vendor_edit') }); - -sub action_ajax_autocomplete { - my ($self, %params) = @_; - - my $limit = $::form->{limit} || 20; - my $type = $::form->{type} || {}; - my $query = { ilike => "%$::form->{term}%" }; - my @filter; - push @filter, ($::form->{column}) - ? ($::form->{column} => $query) - : (or => [ customernumber => $query, name => $query ]); - - $self->{customers} = SL::DB::Manager::Customer->get_all(query => [ @filter ], limit => $limit); - $self->{value} = $::form->{column} || 'name'; - - $self->render('ct/ajax_autocomplete2', { layout => 0, type => 'json' }); -} -- 2.20.1