X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fedit%2Fsvc_domain.cgi;h=54a933deecf4173eb64e965f350e10398220875a;hp=56ba604bfa94950fbb550ca9818bc1f2b1e6e1cb;hb=74e058c8a010ef6feb539248a550d0bb169c1e94;hpb=5e05724a635a22776f1b973f5d7e77989da4e048 diff --git a/httemplate/edit/svc_domain.cgi b/httemplate/edit/svc_domain.cgi index 56ba604bf..54a933dee 100755 --- a/httemplate/edit/svc_domain.cgi +++ b/httemplate/edit/svc_domain.cgi @@ -7,16 +7,56 @@ ->New +<% ntable("#cccccc",2) %> + +
Domain
+>Registered elsewhere
-
Purpose/Description:
+
+% }
+
+
+
+<% include('svc_domain/communigate-basics.html',
+ 'svc_domain' => $svc_domain,
+ 'part_svc' => $part_svc,
+ 'communigate' => $communigate,
+ )
+%>
+
+
+
+
+<% include('svc_domain/communigate-acct_defaults.html',
+ 'svc_domain' => $svc_domain,
+ 'part_svc' => $part_svc,
+ 'communigate' => $communigate,
+ )
+%>
+
+
@@ -27,7 +67,9 @@
die "access denied"
unless $FS::CurrentUser::CurrentUser->access_right('Provision customer service'); #something else more specific?
-my($svcnum, $pkgnum, $svcpart, $kludge_action, $purpose, $part_svc,
+my $conf = new FS::Conf;
+
+my($svcnum, $pkgnum, $svcpart, $kludge_action, $part_svc,
$svc_domain);
if ( $cgi->param('error') ) {
@@ -38,7 +80,6 @@ if ( $cgi->param('error') ) {
$pkgnum = $cgi->param('pkgnum');
$svcpart = $cgi->param('svcpart');
$kludge_action = $cgi->param('action');
- $purpose = $cgi->param('purpose');
$part_svc = qsearchs('part_svc', { 'svcpart' => $svcpart } );
die "No part_svc entry!" unless $part_svc;
@@ -61,7 +102,6 @@ if ( $cgi->param('error') ) {
} else { #editing
$kludge_action = '';
- $purpose = '';
my($query) = $cgi->keywords;
$query =~ /^(\d+)$/ or die "unparsable svcnum";
$svcnum=$1;
@@ -82,6 +122,15 @@ my $action = $svcnum ? 'Edit' : 'Add';
my $svc = $part_svc->getfield('svc');
+my $communigate = scalar($part_svc->part_export('communigate_pro'));
+ # || scalar($part_svc->part_export('communigate_pro_singledomain'));
+
+# Find the first export that does domain registration
+my @exports = grep $_->can('registrar'), $part_svc->part_export;
+my $export = $exports[0];
+# If we have a domain registration export, get the registrar object
+my $registrar = $export ? $export->registrar : '';
+
my $otaker = getotaker;
my $domain = $svc_domain->domain;