diff options
-rw-r--r-- | FS/FS/Schema.pm | 1 | ||||
-rw-r--r-- | FS/FS/part_export/communigate_pro.pm | 4 | ||||
-rw-r--r-- | FS/FS/svc_CGP_Mixin.pm | 18 | ||||
-rw-r--r-- | FS/FS/svc_domain.pm | 7 | ||||
-rw-r--r-- | httemplate/edit/svc_domain/communigate-basics.html | 18 | ||||
-rw-r--r-- | httemplate/view/svc_domain/basics.html | 7 |
6 files changed, 55 insertions, 0 deletions
diff --git a/FS/FS/Schema.pm b/FS/FS/Schema.pm index 4c85da1..b8ba5b2 100644 --- a/FS/FS/Schema.pm +++ b/FS/FS/Schema.pm @@ -1775,6 +1775,7 @@ sub tables_hashref { 'trailer', 'text', 'NULL', '', '', '', 'cgp_aliases', 'varchar', 'NULL', 255, '', '', 'cgp_accessmodes','varchar','NULL', 255, '', '', #DomainAccessModes + 'cgp_certificatetype','varchar','NULL', $char_d, '', '', #settings 'acct_def_password_selfchange', 'char', 'NULL', 1, '', '', 'acct_def_password_recover', 'char', 'NULL', 1, 'Y', '', diff --git a/FS/FS/part_export/communigate_pro.pm b/FS/FS/part_export/communigate_pro.pm index cc96086..a3ec5e0 100644 --- a/FS/FS/part_export/communigate_pro.pm +++ b/FS/FS/part_export/communigate_pro.pm @@ -173,6 +173,8 @@ sub _export_insert_svc_domain { if $svc_domain->parent_svcnum; $settings{'TrailerText'} = $svc_domain->trailer if $svc_domain->trailer; + $settings{'CertificateType'} = $svc_domain->cgp_certificatetype + if $svc_domain->cgp_certificatetype; my @options = ( $create, $svc_domain->domain, \%settings ); @@ -426,6 +428,8 @@ sub _export_replace_svc_domain { $settings{'AdminDomainName'} = $new->parent_svcnum ? $new->parent_svc_x->domain : '' if $old->parent_svcnum != $new->parent_svcnum; + $settings{'CertificateType'} = $new->cgp_certificatetype + if $old->cgp_certificatetype ne $new->cgp_certificatetype; if ( keys %settings ) { my $error = $self->communigate_pro_queue( $new->svcnum, diff --git a/FS/FS/svc_CGP_Mixin.pm b/FS/FS/svc_CGP_Mixin.pm index 489e979..2eee37a 100644 --- a/FS/FS/svc_CGP_Mixin.pm +++ b/FS/FS/svc_CGP_Mixin.pm @@ -131,6 +131,24 @@ sub cgp_emptytrash_values { ]; } +=item cgp_certificatetype_values + +Returns an arrayref of possible CertificateType values. + +=cut + +#http://www.communigate.com/cgatepro/PKI.html + +sub cgp_certificatetype_values { + + [ '', #<option value="-1">default(Test) + 'Enabled', + 'Disabled', + 'Test', + ]; + +} + =back =head1 BUGS diff --git a/FS/FS/svc_domain.pm b/FS/FS/svc_domain.pm index dde6d3c..a97f35b 100644 --- a/FS/FS/svc_domain.pm +++ b/FS/FS/svc_domain.pm @@ -133,6 +133,13 @@ sub table_info { disable_inventory => 1, disable_select => 1, }, + 'cgp_certificatetype' => { + label => 'Communigate PKI services', + type => 'select', + select_list => __PACKAGE__->cgp_certificatetype_values, + disable_inventory => 1, + disable_select => 1, + }, 'acct_def_cgp_accessmodes' => { label => 'Acct. default Communigate enabled services', diff --git a/httemplate/edit/svc_domain/communigate-basics.html b/httemplate/edit/svc_domain/communigate-basics.html index ff401c0..dbad35f 100644 --- a/httemplate/edit/svc_domain/communigate-basics.html +++ b/httemplate/edit/svc_domain/communigate-basics.html @@ -56,6 +56,24 @@ % } % if ( $communigate +% && $part_svc->part_svc_column('cgp_certificatetype')->columnflag ne 'F' ) +% { + + <% include('/elements/tr-select.html', + 'label' => 'PKI services', + 'field' => 'cgp_certificatetype', + 'options' => $svc_domain->cgp_certificatetype_values, + 'labels' => { + '' => 'default (Test)', + }, + 'curr_value' => $svc_domain->cgp_certificatetype, + ) + %> +% } else { + <INPUT TYPE="hidden" NAME="cgp_certificatetype" VALUE="<% $svc_domain->cgp_certificatetype() |h %>"> +% } + +% if ( $communigate % && $part_svc->part_svc_column('trailer')->columnflag ne 'F' ) % { diff --git a/httemplate/view/svc_domain/basics.html b/httemplate/view/svc_domain/basics.html index 1915719..71b7ca4 100644 --- a/httemplate/view/svc_domain/basics.html +++ b/httemplate/view/svc_domain/basics.html @@ -86,6 +86,13 @@ Service #<B><% $svcnum %></B> </TR> % } +% if ( $svc_domain->cgp_certificatetype ) { + <TR> + <TD ALIGN="right">PKI services</TD> + <TD BGCOLOR="#ffffff"><% $svc_domain->cgp_certificatetype %></TD> + </TR> +% } + % if ( $svc_domain->trailer ) { <TR> <TD ALIGN="right">Mail trailer</TD> |