1 <& elements/svc_Common.html,
2 'title' => 'Fiber Search Results',
3 'name' => 'fiber services',
5 'count_query' => $query->{'count_query'},
13 FS::UI::Web::cust_header($cgi->param('cust_fields')),
15 'fields' => [ 'svcnum',
17 sub { my $svc = shift;
18 join('-', $svc->shelf, $svc->card, $svc->olt_port)
23 \&FS::UI::Web::cust_fields,
31 FS::UI::Web::cust_links($cgi->param('cust_fields')),
33 'align' => 'rlllll'. FS::UI::Web::cust_aligns(),
36 FS::UI::Web::cust_colors(),
40 FS::UI::Web::cust_styles(),
46 die "access denied" unless
47 $FS::CurrentUser::CurrentUser->access_right([ 'Services: Fiber',
51 my $conf = new FS::Conf;
54 if ( $cgi->param('magic') eq 'unlinked' ) {
55 %search_hash = ( 'unlinked' => 1 );
57 foreach (qw( custnum agentnum svcpart cust_fields
58 ont_typenum oltnum shelf olt_port card vlan )) {
59 $search_hash{$_} = $cgi->param($_) if defined($cgi->param($_));
63 my $query = FS::svc_fiber->search(\%search_hash);
64 $query->{addl_from} .= ' LEFT JOIN fiber_olt USING (oltnum) ';
65 $query->{select} .= ', oltname';
67 my $link = [ $p.'view/svc_fiber.cgi?', 'svcnum' ];