1 <% include('elements/search.html',
2 'title' => 'Prospect Search Results',
3 'name_singular' => 'prospect',
5 'count_query' => $count_query,
10 'fields' => [ 'prospectnum',
15 [ { 'data' => $_->line, }, ];
23 '', #link to contact edit???
31 unless $FS::CurrentUser::CurrentUser->access_right('List prospects');
35 #$search_hash{'query'} = $cgi->keywords;
42 for my $param ( @scalars ) {
43 $search_hash{$param} = scalar( $cgi->param($param) )
44 if $cgi->param($param);
49 # $search_hash{$param} = [ $cgi->param($param) ];
53 #foreach my $field (qw( signupdate )) {
55 # my($beginning, $ending) = FS::UI::Web::parse_beginning_ending($cgi, $field);
57 # next if $beginning == 0 && $ending == 4294967295;
58 # #or $disable{$cgi->param('status')}->{$field};
60 # $search_hash{$field} = [ $beginning, $ending ];
64 my $query = FS::prospect_main->search(\%search_hash);
65 my $count_query = delete($query->{'count_query'});
66 #my @extra_headers = @{ delete($query->{'extra_headers'}) };
67 #my @extra_fields = @{ delete($query->{'extra_fields'}) };
70 my $prospect_main = shift;
71 [ "${p}view/prospect_main.html?", 'prospectnum' ];