diff options
author | cvs2git <cvs2git> | 2010-12-27 00:04:45 +0000 |
---|---|---|
committer | cvs2git <cvs2git> | 2010-12-27 00:04:45 +0000 |
commit | c82d349f864e6bd9f96fd1156903bc1f7193a203 (patch) | |
tree | e117a87533656110b6acd56fc0ca64289892a9f5 /httemplate/search/qual.cgi | |
parent | 74e058c8a010ef6feb539248a550d0bb169c1e94 (diff) |
This commit was manufactured by cvs2svn to create tag 'TORRUS_1_0_9'.TORRUS_1_0_9
Diffstat (limited to 'httemplate/search/qual.cgi')
-rwxr-xr-x | httemplate/search/qual.cgi | 82 |
1 files changed, 0 insertions, 82 deletions
diff --git a/httemplate/search/qual.cgi b/httemplate/search/qual.cgi deleted file mode 100755 index cf4f3d1..0000000 --- a/httemplate/search/qual.cgi +++ /dev/null @@ -1,82 +0,0 @@ -<% include( 'elements/search.html', - 'title' => 'Qualifications', - 'name_singular' => 'qualification', - 'query' => { 'table' => 'qual', - 'hashref' => $hashref, - 'extra_sql' => $extra_sql, - 'order_by' => 'ORDER BY qualnum DESC', - }, - 'count_query' => "$count_query $extra_sql", - 'header' => [ 'Qualification', - 'Status', - 'Customer or Prospect', - 'Service Telephone Number', - 'Address', - 'Qualified Using', - 'Vendor Qualification #', - ], - 'align' => 'rcccccc', - 'fields' => [ 'qualnum', - sub { - my $self = shift; - $self->status_long; - }, - sub { - my $self = shift; - my $cust_or_prospect = $self->cust_or_prospect; - return $cust_or_prospect->name - if $cust_or_prospect->get('custnum'); - return "Prospect #".$cust_or_prospect->prospectnum - if $cust_or_prospect->get('prospectnum'); - ''; - }, - 'phonenum', - sub { - my $self = shift; - my %location_hash = $self->location; - # ugh... - if ( %location_hash ) { - my $loc = new FS::cust_location(\%location_hash); - return $loc->location_label; - } - ''; - }, - sub { - my $self = shift; - my $export = $self->part_export; - my $result = '(manual)'; - $result = $export->exportname if $export; - $result; - }, - 'vendor_qual_id', - ], - 'links' => [ - [ "${p}view/qual.cgi?qualnum=", 'qualnum' ], - '', - '', - '', - '', - '', - '', - ], - ) -%> -<%init> - -die "access denied" - unless $FS::CurrentUser::CurrentUser->access_right('Qualify service'); - -my $hashref = {}; -my $count_query = 'SELECT COUNT(*) FROM qual'; - -my $extra_sql = ''; -if ( $cgi->param('custnum') && $cgi->param('custnum') =~ /^(\d+)$/ ) { - $extra_sql = " where custnum = $1 or locationnum in " - . " (select locationnum from cust_location where custnum = $1)"; -} elsif ( $cgi->param('prospectnum') - && $cgi->param('prospectnum') =~ /^(\d+)$/ ) { - $extra_sql = " where prospectnum = $1 or locationnum in " - . " (select locationnum from cust_location where prospectnum = $1)"; -} - -</%init> |