summaryrefslogtreecommitdiff
path: root/httemplate/misc/whois.cgi
diff options
context:
space:
mode:
authorivan <ivan>2008-12-03 21:15:39 +0000
committerivan <ivan>2008-12-03 21:15:39 +0000
commitff873782e78715891b9d5d2eb5b38c735d372556 (patch)
tree078350a30b03a064e44244f4ccd141cbe460613a /httemplate/misc/whois.cgi
parente3c53b20ac5a7e120562bbd259a19707e9c11cb5 (diff)
fix real customer numbers showing on view pages, RT#4099/4379
Diffstat (limited to 'httemplate/misc/whois.cgi')
-rw-r--r--httemplate/misc/whois.cgi8
1 files changed, 7 insertions, 1 deletions
diff --git a/httemplate/misc/whois.cgi b/httemplate/misc/whois.cgi
index 35d0eccc9..533b2d7a8 100644
--- a/httemplate/misc/whois.cgi
+++ b/httemplate/misc/whois.cgi
@@ -1,6 +1,6 @@
<% include("/elements/header.html","Whois $domain", menubar(
( $custnum
- ? ( "View this customer (#$custnum)" => "${p}view/cust_main.cgi?$custnum",
+ ? ( "View this customer (#$display_custnum)" => "${p}view/cust_main.cgi?$custnum",
)
: ()
),
@@ -17,6 +17,12 @@ my $svcnum = $cgi->param('svcnum');
my $custnum = $cgi->param('custnum');
my $domain = $cgi->param('domain');
+my $display_custnum;
+if ( $custnum ) {
+ my $cust_main = qsearchs('cust_main', { 'custnum' => $custnum } );
+ $display_custnum = $cust_main->display_custnum;
+}
+
my $whois = eval { whois($domain) };
if ( $@ ) {
( $whois = $@ ) =~ s/ at \/.*Net\/Whois\/Raw\.pm line \d+.*$//s;