3 %# <% include("/elements/header.html","View $svcdomain") %>
4 <% include("/elements/header.html","View domain") %>
5 <% include( '/elements/small_custview.html', $custnum, '', 1,
6 "${p}view/cust_main.cgi") %>
11 <% include("/elements/header.html",'View domain', menubar(
12 "Cancel this (unaudited) domain" =>
13 "javascript:areyousure('${p}misc/cancel-unaudited.cgi?$svcnum', 'Delete $domain and all records?')",
19 <% include('/elements/error.html') %>
21 <% include('svc_domain/basics.html', $svc_domain,
22 'part_svc' => $part_svc,
23 'custnum' => $custnum,
28 <% include('svc_domain/acct_defaults.html', $svc_domain,
29 'part_svc' => $part_svc,
34 <% include('svc_domain/dns.html', $svc_domain ) %>
37 <% include('elements/svc_export_settings.html', $svc_domain) %>
39 <% joblisting({'svcnum'=>$svcnum}, 1) %>
41 <% include('/elements/footer.html') %>
45 unless $FS::CurrentUser::CurrentUser->access_right('View customer services');
47 my $conf = new FS::Conf;
49 my($query) = $cgi->keywords;
52 my $svc_domain = qsearchs({
53 'select' => 'svc_domain.*',
54 'table' => 'svc_domain',
55 'addl_from' => ' LEFT JOIN cust_svc USING ( svcnum ) '.
56 ' LEFT JOIN cust_pkg USING ( pkgnum ) '.
57 ' LEFT JOIN cust_main USING ( custnum ) ',
58 'hashref' => {'svcnum'=>$svcnum},
59 'extra_sql' => ' AND '. $FS::CurrentUser::CurrentUser->agentnums_sql(
60 'null_right' => 'View/link unlinked services'
63 die "Unknown svcnum" unless $svc_domain;
65 my $cust_svc = qsearchs('cust_svc',{'svcnum'=>$svcnum});
66 my $pkgnum = $cust_svc->getfield('pkgnum');
67 my($cust_pkg, $custnum, $display_custnum);
69 $cust_pkg = qsearchs('cust_pkg', {'pkgnum'=>$pkgnum} );
70 $custnum = $cust_pkg->custnum;
71 $display_custnum = $cust_pkg->cust_main->display_custnum;
77 my $part_svc = qsearchs('part_svc',{'svcpart'=> $cust_svc->svcpart } );
78 die "Unknown svcpart" unless $part_svc;
80 my $domain = $svc_domain->domain;