diff options
author | Mark Wells <mark@freeside.biz> | 2014-11-27 15:21:29 -0800 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2014-11-27 15:21:29 -0800 |
commit | 1af8ff7f48f7259fc99f090c301c84b9680fdb4d (patch) | |
tree | e21d72df5e6dd2eddebc8debc3b954bf2e0830e8 /FS/FS/UI | |
parent | 0f0bc1ef7aafc6b3869c0f71ee2528c1c9897ce6 (diff) |
svc_circuit, #23879, #25933, #30830
Diffstat (limited to 'FS/FS/UI')
-rw-r--r-- | FS/FS/UI/Web.pm | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/FS/FS/UI/Web.pm b/FS/FS/UI/Web.pm index 99c3560..e138692 100644 --- a/FS/FS/UI/Web.pm +++ b/FS/FS/UI/Web.pm @@ -113,16 +113,16 @@ sub svc_url { if $DEBUG; if ( $opt{m}->interp->comp_exists("/$opt{action}/$svcdb.cgi") ) { $url = "$svcdb.cgi?"; + } elsif ( $opt{m}->interp->comp_exists("/$opt{action}/$svcdb.html") ) { + $url = "$svcdb.html?"; } else { - my $generic = $opt{action} eq 'search' ? 'cust_svc' : 'svc_Common'; $url = "$generic.html?svcdb=$svcdb;"; $url .= 'svcnum=' if $query =~ /^\d+(;|$)/ or $query eq ''; } - import FS::CGI 'rooturl'; #WTF! why is this necessary - my $return = rooturl(). "$opt{action}/$url$query"; + my $return = FS::CGI::rooturl(). "$opt{action}/$url$query"; $return = qq!<A HREF="$return">! if $opt{ahref}; @@ -574,6 +574,19 @@ sub cust_aligns { } } +=item cust_links + +Returns an array of links to view/cust_main.cgi, for use with cust_fields. + +=cut + +sub cust_links { + my $link = [ FS::CGI::rooturl().'view/cust_main.cgi?', 'custnum' ]; + + return map { $_ eq 'cust_status_label' ? '' : $link } + @cust_fields; +} + =item is_mobile Utility function to determine if the client is a mobile browser. |