RT#42393: Verification cust_pay_pending handling in history & report
[freeside.git] / httemplate / search / svc_broadband.cgi
index 6b16ace..8cdf29d 100755 (executable)
@@ -23,6 +23,7 @@
                                  'ip_addr',
                                  sub {
                                    $cust_pkg_cache{$_[0]->svcnum} ||= $_[0]->cust_svc->cust_pkg;
+                                   return '' unless $cust_pkg_cache{$_[0]->svcnum};
                                    $cust_pkg_cache{$_[0]->svcnum}->ucfirst_status
                                  },
                                  \&FS::UI::Web::cust_fields,
@@ -46,6 +47,8 @@
                                  (map '', @tower_fields),
                                  '',
                                  sub {
+                                   $cust_pkg_cache{$_[0]->svcnum} ||= $_[0]->cust_svc->cust_pkg;
+                                   return '' unless $cust_pkg_cache{$_[0]->svcnum};
                                    my $c = FS::cust_pkg::statuscolors;
                                    $c->{$cust_pkg_cache{$_[0]->svcnum}->status };
                                  }, # pkg status
@@ -121,5 +124,9 @@ my $html_init = include('/elements/email-link.html',
                   'search_hash' => \%search_hash,
                   'table' => 'svc_broadband' 
                 );
+$html_init .= ' | ' .
+  '<a href="' .
+  $fsurl . 'search/svc_broadband-map.html?' . $cgi->query_string .
+  '">' . emt('View a map of these services') . '</a>';
 
 </%init>