1 <% include("/elements/header.html", "Website View", menubar(
3 ? ( "View this customer (#$display_custnum)" => "${p}view/cust_main.cgi?$custnum",
5 : ( "Cancel this (unaudited) website" =>
6 "${p}misc/cancel-unaudited.cgi?$svcnum" )
11 <A HREF="<% $p %>edit/svc_www.cgi?<% $svcnum %>">Edit this information</A><BR>
13 <% ntable("#cccccc", 2) %>
16 <TD ALIGN="right">Service number</TD>
17 <TD BGCOLOR="#ffffff"><% $svcnum %></TD>
20 <TD ALIGN="right">Website name</TD>
21 <TD BGCOLOR="#ffffff"><A HREF="http://<% $www %>"><% $www %></A></TD>
24 % if ( $part_svc->part_svc_column('usersvc')->columnflag ne 'F'
25 % || $part_svc->part_svc_column('usersvc')->columnvalue !~ /^\s*$/) {
28 <TD ALIGN="right">Account</TD>
29 <TD BGCOLOR="#ffffff">
31 <A HREF="<% $p %>view/svc_acct.cgi?<% $usersvc %>"><% $email %></A>
41 <TD ALIGN="right">Config lines</TD>
42 <TD BGCOLOR="#ffffff"><PRE><% join("\n", $svc_www->config) |h %></PRE></TD>
45 % foreach (sort { $a cmp $b } $svc_www->virtual_fields) {
46 <% $svc_www->pvf($_)->widget('HTML', 'view', $svc_www->getfield($_)) %>
52 <% joblisting({'svcnum'=>$svcnum}, 1) %>
54 <% include('/elements/footer.html') %>
58 unless $FS::CurrentUser::CurrentUser->access_right('View customer services');
60 my($query) = $cgi->keywords;
63 my $svc_www = qsearchs({
64 'select' => 'svc_www.*',
66 'addl_from' => ' LEFT JOIN cust_svc USING ( svcnum ) '.
67 ' LEFT JOIN cust_pkg USING ( pkgnum ) '.
68 ' LEFT JOIN cust_main USING ( custnum ) ',
69 'hashref' => { 'svcnum' => $svcnum },
70 'extra_sql' => ' AND '. $FS::CurrentUser::CurrentUser->agentnums_sql(
71 'null_right' => 'View/link unlinked services'
73 }) or die "svc_www: Unknown svcnum $svcnum";
75 #false laziness w/all svc_*.cgi
76 my $cust_svc = qsearchs( 'cust_svc', { 'svcnum' => $svcnum } );
77 my $pkgnum = $cust_svc->getfield('pkgnum');
78 my($cust_pkg, $custnum, $display_custnum);
80 $cust_pkg = qsearchs( 'cust_pkg', { 'pkgnum' => $pkgnum } );
81 $custnum = $cust_pkg->custnum;
82 $display_custnum = $cust_pkg->cust_main->display_custnum;
89 my $part_svc=qsearchs('part_svc',{'svcpart'=>$cust_svc->svcpart})
90 or die "svc_www: Unknown svcpart" . $cust_svc->svcpart;
92 my $usersvc = $svc_www->usersvc;
96 $svc_acct = qsearchs('svc_acct', { 'svcnum' => $usersvc } )
97 or die "svc_www: Unknown usersvc $usersvc";
98 $email = $svc_acct->email;
101 my $domain_record = qsearchs('domain_record', { 'recnum' => $svc_www->recnum } )
102 or die "svc_www: Unknown recnum ". $svc_www->recnum;
104 my $www = $domain_record->zone;