summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--FS/FS/Schema.pm34
-rw-r--r--FS/FS/part_export/communigate_pro.pm30
-rw-r--r--FS/FS/svc_acct.pm188
-rw-r--r--FS/FS/svc_domain.pm130
-rwxr-xr-xhttemplate/edit/svc_acct.cgi123
-rwxr-xr-xhttemplate/edit/svc_domain.cgi118
-rw-r--r--httemplate/view/svc_acct/basics.html11
-rw-r--r--httemplate/view/svc_domain/acct_defaults.html29
8 files changed, 603 insertions, 60 deletions
diff --git a/FS/FS/Schema.pm b/FS/FS/Schema.pm
index a59156afd..67cf606fe 100644
--- a/FS/FS/Schema.pm
+++ b/FS/FS/Schema.pm
@@ -1660,20 +1660,31 @@ sub tables_hashref {
'last_login', @date_type, '', '',
'last_logout', @date_type, '', '',
#communigate pro fields (quota = MaxAccountSize)
+ 'cgp_aliases', 'varchar', 'NULL', 255, '', '',
+ #settings
+ 'cgp_type', 'varchar', 'NULL', $char_d, '', '', #AccountType
'file_quota', 'varchar', 'NULL', $char_d, '', '', #MaxWebSize
'file_maxnum', 'varchar', 'NULL', $char_d, '', '', #MaxWebFiles
'file_maxsize', 'varchar', 'NULL', $char_d, '', '', #MaxFileSize
'cgp_accessmodes', 'varchar', 'NULL', 255, '', '', #AccessModes
'password_selfchange','char', 'NULL', 1, '', '', #PWDAllowed
'password_recover', 'char', 'NULL', 1, 'Y','', #PasswordRecovery
- 'cgp_type', 'varchar', 'NULL', $char_d, '', '', #AccountType
- 'cgp_aliases', 'varchar', 'NULL', 255, '', '',
- 'cgp_deletemode', 'varchar', 'NULL', $char_d, '', '', #DeleteMode
- 'cgp_emptytrash', 'varchar', 'NULL', $char_d, '', '', #EmptyTrash
'cgp_rulesallowed','varchar', 'NULL', $char_d, '', '', #RulesAllowed
'cgp_rpopallowed', 'char', 'NULL', 1, '', '', #RPOPAllowed
'cgp_mailtoall', 'char', 'NULL', 1, '', '', #MailToAll
'cgp_addmailtrailer', 'char', 'NULL', 1, '', '', #AddMailTrailer
+ #XXX archive messages, mailing lists
+ #preferences
+ 'cgp_deletemode', 'varchar', 'NULL', $char_d, '', '', #DeleteMode
+ 'cgp_emptytrash', 'varchar', 'NULL', $char_d, '', '', #EmptyTrash
+ 'cgp_language', 'varchar', 'NULL', $char_d, '', '', #Language
+ 'cgp_timezone', 'varchar', 'NULL', $char_d, '', '', #TimeZone
+ 'cgp_skinname', 'varchar', 'NULL', $char_d, '', '', #SkinName
+ #XXX pronto style?
+ 'cgp_sendmdnmode', 'varchar', 'NULL', $char_d, '', '', #SendMDNMode
+ #mail
+#vacation message, redirect all mail, mail rules
+ #XXX RPOP settings
],
'primary_key' => 'svcnum',
#'unique' => [ [ 'username', 'domsvc' ] ],
@@ -1722,6 +1733,7 @@ sub tables_hashref {
'trailer', 'text', 'NULL', '', '', '',
'cgp_aliases', 'varchar', 'NULL', 255, '', '',
'cgp_accessmodes','varchar','NULL', 255, '', '', #DomainAccessModes
+ #settings
'acct_def_password_selfchange','char', 'NULL', 1, '', '',
'acct_def_password_recover', 'char', 'NULL', 1, 'Y', '',
'acct_def_cgp_accessmodes', 'varchar', 'NULL', 255, '', '',
@@ -1729,13 +1741,21 @@ sub tables_hashref {
'acct_def_file_quota', 'varchar', 'NULL', $char_d, '', '',
'acct_def_file_maxnum', 'varchar', 'NULL', $char_d, '', '',
'acct_def_file_maxsize', 'varchar', 'NULL', $char_d, '', '',
- 'acct_def_cgp_deletemode', 'varchar', 'NULL', $char_d, '', '',
- 'acct_def_cgp_emptytrash', 'varchar', 'NULL', $char_d, '', '',
'acct_def_cgp_rulesallowed','varchar', 'NULL', $char_d, '', '',
'acct_def_cgp_rpopallowed', 'char', 'NULL', 1, '', '',
'acct_def_cgp_mailtoall', 'char', 'NULL', 1, '', '',
'acct_def_cgp_addmailtrailer', 'char', 'NULL', 1, '', '',
-
+ #XXX archive messages
+ #preferences
+ 'acct_def_cgp_deletemode', 'varchar', 'NULL', $char_d, '', '',
+ 'acct_def_cgp_emptytrash', 'varchar', 'NULL', $char_d, '', '',
+ 'acct_def_cgp_language', 'varchar', 'NULL', $char_d, '', '',
+ 'acct_def_cgp_timezone', 'varchar', 'NULL', $char_d, '', '',
+ 'acct_def_cgp_skinname', 'varchar', 'NULL', $char_d, '', '',
+ #XXX pronto style?
+ 'acct_def_cgp_sendmdnmode', 'varchar', 'NULL', $char_d, '', '',
+ #mail
+ #XXX rules, archive rule, spam foldering rule(s)
],
'primary_key' => 'svcnum',
'unique' => [ ],
diff --git a/FS/FS/part_export/communigate_pro.pm b/FS/FS/part_export/communigate_pro.pm
index a666ca0b2..8148b5a33 100644
--- a/FS/FS/part_export/communigate_pro.pm
+++ b/FS/FS/part_export/communigate_pro.pm
@@ -109,7 +109,11 @@ sub _export_insert_svc_acct {
my %prefs = ();
$prefs{'DeleteMode'} = $svc_acct->cgp_deletemode if $svc_acct->cgp_deletemode;
$prefs{'EmptyTrash'} = $svc_acct->cgp_emptytrash if $svc_acct->cgp_emptytrash;
- #phase 2: language, time zone, layout, pronto style, send read receipts
+ $prefs{'Language'} = $svc_acct->cgp_language if $svc_acct->cgp_language;
+ $prefs{'TimeZone'} = $svc_acct->cgp_timezone if $svc_acct->cgp_timezone;
+ $prefs{'SkinName'} = $svc_acct->cgp_skinname if $svc_acct->cgp_skinname;
+ #XXX pronto style
+ $prefs{'SendMDNMode'} = $svc_acct->cgp_sendmdnmode if $svc_acct->cgp_sendmdnmode;
if ( keys %prefs ) {
my $pref_err = $self->communigate_pro_queue( $svc_acct->svcnum,
'UpdateAccountPrefs',
@@ -189,8 +193,13 @@ sub _export_insert_svc_domain {
my $pref_err = $self->communigate_pro_queue( $svc_domain->svcnum,
'SetAccountDefaultPrefs',
$svc_domain->domain,
- 'DeleteMode' => $svc_domain->acct_def_cgp_deletemode,
- 'EmptyTrash' => $svc_domain->acct_def_cgp_emptytrash,
+ 'DeleteMode' => $svc_domain->acct_def_cgp_deletemode,
+ 'EmptyTrash' => $svc_domain->acct_def_cgp_emptytrash,
+ 'Language' => $svc_domain->acct_def_cgp_language,
+ 'TimeZone' => $svc_domain->acct_def_cgp_timezone,
+ 'SkinName' => $svc_domain->acct_def_cgp_skinname,
+ #XXX pronto style?
+ 'SendMDNMode' => $svc_domain->acct_def_cgp_sendmdnmode,
);
warn "WARNING: error queueing SetAccountDefaultPrefs job: $pref_err"
if $pref_err;
@@ -310,7 +319,15 @@ sub _export_replace_svc_acct {
if $old->cgp_deletemode ne $new->cgp_deletemode;
$prefs{'EmptyTrash'} = $new->cgp_emptytrash
if $old->cgp_emptytrash ne $new->cgp_emptytrash;
- #phase 2: language, time zone, layout, pronto style, send read receipts
+ $prefs{'Language'} = $new->cgp_language
+ if $old->cgp_language ne $new->cgp_language;
+ $prefs{'TimeZone'} = $new->cgp_timezone
+ if $old->cgp_timezone ne $new->cgp_timezone;
+ $prefs{'SkinName'} = $new->cgp_skinname
+ if $old->cgp_skinname ne $new->cgp_skinname;
+ #XXX pronto style
+ $prefs{'SendMDNMode'} = $new->cgp_sendmdnmode
+ if $old->cgp_sendmdnmode ne $new->cgp_sendmdnmode;
if ( keys %prefs ) {
my $pref_err = $self->communigate_pro_queue( $new->svcnum,
'UpdateAccountPrefs',
@@ -402,6 +419,11 @@ sub _export_replace_svc_domain {
$new->domain,
'DeleteMode' => $new->acct_def_cgp_deletemode,
'EmptyTrash' => $new->acct_def_cgp_emptytrash,
+ 'Language' => $new->acct_def_cgp_language,
+ 'TimeZone' => $new->acct_def_cgp_timezone,
+ 'SkinName' => $new->acct_def_cgp_skinname,
+ #XXX Pronto style
+ 'SendMDNMode' => $new->acct_def_cgp_sendmdnmode,
);
warn "WARNING: error queueing SetAccountDefaultPrefs job: $pref_err"
if $pref_err;
diff --git a/FS/FS/svc_acct.pm b/FS/FS/svc_acct.pm
index 954d03051..666a56ab9 100644
--- a/FS/FS/svc_acct.pm
+++ b/FS/FS/svc_acct.pm
@@ -268,44 +268,12 @@ sub table_info {
disable_fixed => 1,
disable_select => 1,
},
- 'cgp_type'=> {
- label => 'Communigate account type',
- type => 'select',
- select_list => [qw( MultiMailbox TextMailbox MailDirMailbox AGrade BGrade CGrade )],
- disable_inventory => 1,
- disable_select => 1,
- },
- 'cgp_accessmodes' => {
- label => 'Communigate enabled services',
- type => 'communigate_pro-accessmodes',
- disable_inventory => 1,
- disable_select => 1,
- },
- 'cgp_aliases' => {
- label => 'Communigate aliases',
- type => 'text',
- disable_inventory => 1,
- disable_select => 1,
- },
'password_selfchange' => { label => 'Password modification',
type => 'checkbox',
},
'password_recover' => { label => 'Password recovery',
type => 'checkbox',
},
- 'cgp_deletemode' => {
- label => 'Communigate message delete method',
- type => 'select',
- select_list => [ 'Move To Trash', 'Immediately', 'Mark' ],
- disable_inventory => 1,
- disable_select => 1,
- },
- 'cgp_emptytrash' => {
- label => 'Communigate on logout remove trash',
- type => 'text',
- disable_inventory => 1,
- disable_select => 1,
- },
'quota' => {
label => 'Quota', #Mail storage limit
type => 'text',
@@ -434,6 +402,155 @@ sub table_info {
label => 'Last logout',
type => 'disabled',
},
+
+ 'cgp_aliases' => {
+ label => 'Communigate aliases',
+ type => 'text',
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ #settings
+ 'cgp_type'=> {
+ label => 'Communigate account type',
+ type => 'select',
+ select_list => [qw( MultiMailbox TextMailbox MailDirMailbox AGrade BGrade CGrade )],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_accessmodes' => {
+ label => 'Communigate enabled services',
+ type => 'communigate_pro-accessmodes',
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_rulesallowed' => {
+ label => 'Allowed mail rules',
+ type => 'select',
+ select_list => [ '', 'No', 'Filter Only', 'All But Exec', 'Any' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_rpopallowed' => { label => 'RPOP modifications',
+ type => 'checkbox',
+ },
+ 'cgp_mailtoall' => { label => 'Accepts mail to "all"',
+ type => 'checkbox',
+ },
+ 'cgp_addmailtrailer' => { label => 'Add trailer to sent mail',
+ type => 'checkbox',
+ },
+ #XXX archive messages, mailing lists
+
+ #preferences
+ 'cgp_deletemode' => {
+ label => 'Communigate message delete method',
+ type => 'select',
+ select_list => [ 'Move To Trash', 'Immediately', 'Mark' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_emptytrash' => {
+ label => 'Communigate on logout remove trash',
+ type => 'text',
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_language' => {
+ label => 'Communigate language',
+ type => 'select',
+ select_list => [ '', qw( English Arabic Chinese Dutch French German Hebrew Italian Japanese Portuguese Russian Slovak Spanish Thai ) ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_timezone' => {
+ label => 'Communigate time zone',
+ type => 'select',
+ select_list => [ '',
+ 'HostOS',
+ '(+0100) Algeria/Congo',
+ '(+0200) Egypt/South Africa',
+ '(+0300) Saudi Arabia',
+ '(+0400) Oman',
+ '(+0500) Pakistan',
+ '(+0600) Bangladesh',
+ '(+0700) Thailand/Vietnam',
+ '(+0800) China/Malaysia',
+ '(+0900) Japan/Korea',
+ '(+1000) Queensland',
+ '(+1100) Micronesia',
+ '(+1200) Fiji',
+ '(+1300) Tonga/Kiribati',
+ '(+1400) Christmas Islands',
+ '(-0100) Azores/Cape Verde',
+ '(-0200) Fernando de Noronha',
+ '(-0300) Argentina/Uruguay',
+ '(-0400) Venezuela/Guyana',
+ '(-0500) Haiti/Peru',
+ '(-0600) Central America',
+ '(-0700) Arisona',
+ '(-0800) Adamstown',
+ '(-0900) Marquesas Islands',
+ '(-1000) Hawaii/Tahiti',
+ '(-1100) Samoa',
+ 'Asia/Afghanistan',
+ 'Asia/India',
+ 'Asia/Iran',
+ 'Asia/Iraq',
+ 'Asia/Israel',
+ 'Asia/Jordan',
+ 'Asia/Lebanon',
+ 'Asia/Syria',
+ 'Australia/Adelaide',
+ 'Australia/East',
+ 'Australia/NorthernTerritory',
+ 'Europe/Central',
+ 'Europe/Eastern',
+ 'Europe/Moscow',
+ 'Europe/Western',
+ 'GMT (+0000)',
+ 'Newfoundland',
+ 'NewZealand/Auckland',
+ 'NorthAmerica/Alaska',
+ 'NorthAmerica/Atlantic',
+ 'NorthAmerica/Central',
+ 'NorthAmerica/Eastern',
+ 'NorthAmerica/Mountain',
+ 'NorthAmerica/Pacific',
+ 'Russia/Ekaterinburg',
+ 'Russia/Irkutsk',
+ 'Russia/Kamchatka',
+ 'Russia/Krasnoyarsk',
+ 'Russia/Magadan',
+ 'Russia/Novosibirsk',
+ 'Russia/Vladivostok',
+ 'Russia/Yakutsk',
+ 'SouthAmerica/Brasil',
+ 'SouthAmerica/Chile',
+ 'SouthAmerica/Paraguay',
+ ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'cgp_skinname' => {
+ label => 'Communigate layout',
+ type => 'select',
+ select_list => [ '', '***', 'GoldFleece', 'Skin2' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ #XXX pronto style?
+ 'cgp_sendmdnmode' => {
+ label => 'Communigate send read receipts',
+ type => 'select',
+ select_list => [ '', 'Never', 'Manually', 'Automatically' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+
+ #mail
+ #XXX vacation message, redirect all mail, mail rules
+ #XXX RPOP settings
+
},
};
}
@@ -1119,6 +1236,13 @@ sub check {
#preferences
|| $self->ut_alphasn('cgp_deletemode')
|| $self->ut_alphan('cgp_emptytrash')
+ || $self->ut_alphan('cgp_language')
+ || $self->ut_textn('cgp_timezone')
+ || $self->ut_textn('cgp_skinname')
+ #XXX pronto style?
+ || $self->ut_alphan('cgp_sendmdnmode')
+ #XXX vacation message, redirect all mail, mail rules
+ #XXX RPOP settings
;
return $error if $error;
diff --git a/FS/FS/svc_domain.pm b/FS/FS/svc_domain.pm
index 5a593bb05..46605f4a0 100644
--- a/FS/FS/svc_domain.pm
+++ b/FS/FS/svc_domain.pm
@@ -189,8 +189,120 @@ sub table_info {
disable_inventory => 1,
disable_select => 1,
},
-
-
+ 'acct_def_cgp_rulesallowed' => {
+ label => 'Acct. default Allowed mail rules',
+ type => 'select',
+ select_list => [ '', 'No', 'Filter Only', 'All But Exec', 'Any' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'acct_def_cgp_rpopallowed' => {
+ label => 'Acct. default RPOP modifications',
+ type => 'checkbox',
+ },
+ 'acct_def_cgp_mailtoall' => {
+ label => 'Acct. default Accepts mail to "all"',
+ type => 'checkbox',
+ },
+ 'acct_def_cgp_addmailtrailer' => {
+ label => 'Acct. default Add trailer to sent mail',
+ type => 'checkbox',
+ },
+ 'trailer' => {
+ label => 'Mail trailer',
+ type => 'textarea',
+ },
+ 'acct_def_cgp_language' => {
+ label => 'Acct. default language',
+ type => 'select',
+ select_list => [ '', qw( English Arabic Chinese Dutch French German Hebrew Italian Japanese Portuguese Russian Slovak Spanish Thai ) ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'acct_def_cgp_timezone' => {
+ label => 'Acct. default time zone',
+ type => 'select',
+ select_list => [ '',
+ 'HostOS',
+ '(+0100) Algeria/Congo',
+ '(+0200) Egypt/South Africa',
+ '(+0300) Saudi Arabia',
+ '(+0400) Oman',
+ '(+0500) Pakistan',
+ '(+0600) Bangladesh',
+ '(+0700) Thailand/Vietnam',
+ '(+0800) China/Malaysia',
+ '(+0900) Japan/Korea',
+ '(+1000) Queensland',
+ '(+1100) Micronesia',
+ '(+1200) Fiji',
+ '(+1300) Tonga/Kiribati',
+ '(+1400) Christmas Islands',
+ '(-0100) Azores/Cape Verde',
+ '(-0200) Fernando de Noronha',
+ '(-0300) Argentina/Uruguay',
+ '(-0400) Venezuela/Guyana',
+ '(-0500) Haiti/Peru',
+ '(-0600) Central America',
+ '(-0700) Arisona',
+ '(-0800) Adamstown',
+ '(-0900) Marquesas Islands',
+ '(-1000) Hawaii/Tahiti',
+ '(-1100) Samoa',
+ 'Asia/Afghanistan',
+ 'Asia/India',
+ 'Asia/Iran',
+ 'Asia/Iraq',
+ 'Asia/Israel',
+ 'Asia/Jordan',
+ 'Asia/Lebanon',
+ 'Asia/Syria',
+ 'Australia/Adelaide',
+ 'Australia/East',
+ 'Australia/NorthernTerritory',
+ 'Europe/Central',
+ 'Europe/Eastern',
+ 'Europe/Moscow',
+ 'Europe/Western',
+ 'GMT (+0000)',
+ 'Newfoundland',
+ 'NewZealand/Auckland',
+ 'NorthAmerica/Alaska',
+ 'NorthAmerica/Atlantic',
+ 'NorthAmerica/Central',
+ 'NorthAmerica/Eastern',
+ 'NorthAmerica/Mountain',
+ 'NorthAmerica/Pacific',
+ 'Russia/Ekaterinburg',
+ 'Russia/Irkutsk',
+ 'Russia/Kamchatka',
+ 'Russia/Krasnoyarsk',
+ 'Russia/Magadan',
+ 'Russia/Novosibirsk',
+ 'Russia/Vladivostok',
+ 'Russia/Yakutsk',
+ 'SouthAmerica/Brasil',
+ 'SouthAmerica/Chile',
+ 'SouthAmerica/Paraguay',
+ ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ 'acct_def_cgp_skinname' => {
+ label => 'Acct. default layout',
+ type => 'select',
+ select_list => [ '', '***', 'GoldFleece', 'Skin2' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
+ #XXX pronto style?
+ 'acct_def_cgp_sendmdnmode' => {
+ label => 'Acct. default send read receipts',
+ type => 'select',
+ select_list => [ '', 'Never', 'Manually', 'Automatically' ],
+ disable_inventory => 1,
+ disable_select => 1,
+ },
},
};
}
@@ -428,12 +540,22 @@ sub check {
|| $self->ut_alphan('acct_def_file_quota')
|| $self->ut_alphan('acct_def_maxnum')
|| $self->ut_alphan('acct_def_maxsize')
- || $self->ut_alphasn('acct_def_cgp_deletemode')
- || $self->ut_alphan('acct_def_cgp_emptytrash')
+ #settings
|| $self->ut_alphasn('acct_def_cgp_rulesallowed')
|| $self->ut_enum('acct_def_cgp_rpopallowed', [ '', 'Y' ])
|| $self->ut_enum('acct_def_cgp_mailtoall', [ '', 'Y' ])
|| $self->ut_enum('acct_def_cgp_addmailtrailer', [ '', 'Y' ])
+ #XXX archive messages
+ #preferences
+ || $self->ut_alphasn('acct_def_cgp_deletemode')
+ || $self->ut_alphan('acct_def_cgp_emptytrash')
+ || $self->ut_alphan('acct_def_cgp_language')
+ || $self->ut_textn('acct_def_cgp_timezone')
+ || $self->ut_textn('acct_def_cgp_skinname')
+ #XXX pronto style?
+ || $self->ut_alphan('acct_def_cgp_sendmdnmode')
+ #mail
+ #XXX rules, archive rule, spam foldering rule(s)
;
return $error if $error;
diff --git a/httemplate/edit/svc_acct.cgi b/httemplate/edit/svc_acct.cgi
index 35c9006f6..bed0aaac1 100755
--- a/httemplate/edit/svc_acct.cgi
+++ b/httemplate/edit/svc_acct.cgi
@@ -333,8 +333,6 @@ Service # <% $svcnum ? "<B>$svcnum</B>" : " (NEW)" %><BR>
% if ( $communigate ) {
-% #preferences
-
<% include('/elements/tr-checkbox.html',
'label' => 'Password recovery',
'field' => 'password_recover',
@@ -378,6 +376,8 @@ Service # <% $svcnum ? "<B>$svcnum</B>" : " (NEW)" %><BR>
)
%>
+% #preferences
+
%# false laziness w/svc_domain acct_def
<TR>
<TD ALIGN="right">Message delete method</TD>
@@ -397,13 +397,126 @@ Service # <% $svcnum ? "<B>$svcnum</B>" : " (NEW)" %><BR>
<TD><INPUT TYPE="text" NAME="cgp_emptytrash" VALUE="<% $svc_acct->cgp_emptytrash %>"></TD>
</TR>
-%#XXX language, time zone, layout, printo style, send read receipts
+ <% include('/elements/tr-select.html',
+ 'label' => 'Language',
+ 'field' => 'cgp_language',
+ 'options' => [ '', qw( English Arabic Chinese Dutch French German Hebrew Italian Japanese Portuguese Russian Slovak Spanish Thai ) ],
+ 'labels' => {
+ '' => 'default (English)',
+ },
+ 'curr_value' => $svc_acct->cgp_language,
+ )
+ %>
+
+ <% include('/elements/tr-select.html',
+ 'label' => 'Time zone',
+ 'field' => 'cgp_timezone',
+ 'options' => [
+ 'HostOS',
+ '(+0100) Algeria/Congo',
+ '(+0200) Egypt/South Africa',
+ '(+0300) Saudi Arabia',
+ '(+0400) Oman',
+ '(+0500) Pakistan',
+ '(+0600) Bangladesh',
+ '(+0700) Thailand/Vietnam',
+ '(+0800) China/Malaysia',
+ '(+0900) Japan/Korea',
+ '(+1000) Queensland',
+ '(+1100) Micronesia',
+ '(+1200) Fiji',
+ '(+1300) Tonga/Kiribati',
+ '(+1400) Christmas Islands',
+ '(-0100) Azores/Cape Verde',
+ '(-0200) Fernando de Noronha',
+ '(-0300) Argentina/Uruguay',
+ '(-0400) Venezuela/Guyana',
+ '(-0500) Haiti/Peru',
+ '(-0600) Central America',
+ '(-0700) Arisona',
+ '(-0800) Adamstown',
+ '(-0900) Marquesas Islands',
+ '(-1000) Hawaii/Tahiti',
+ '(-1100) Samoa',
+ 'Asia/Afghanistan',
+ 'Asia/India',
+ 'Asia/Iran',
+ 'Asia/Iraq',
+ 'Asia/Israel',
+ 'Asia/Jordan',
+ 'Asia/Lebanon',
+ 'Asia/Syria',
+ 'Australia/Adelaide',
+ 'Australia/East',
+ 'Australia/NorthernTerritory',
+ 'Europe/Central',
+ 'Europe/Eastern',
+ 'Europe/Moscow',
+ 'Europe/Western',
+ 'GMT (+0000)',
+ 'Newfoundland',
+ 'NewZealand/Auckland',
+ 'NorthAmerica/Alaska',
+ 'NorthAmerica/Atlantic',
+ 'NorthAmerica/Central',
+ 'NorthAmerica/Eastern',
+ 'NorthAmerica/Mountain',
+ 'NorthAmerica/Pacific',
+ 'Russia/Ekaterinburg',
+ 'Russia/Irkutsk',
+ 'Russia/Kamchatka',
+ 'Russia/Krasnoyarsk',
+ 'Russia/Magadan',
+ 'Russia/Novosibirsk',
+ 'Russia/Vladivostok',
+ 'Russia/Yakutsk',
+ 'SouthAmerica/Brasil',
+ 'SouthAmerica/Chile',
+ 'SouthAmerica/Paraguay',
+ ],
+ 'labels' => {
+ '' => 'default (HostOS)',
+ },
+ 'curr_value' => $svc_acct->cgp_timezone,
+ )
+ %>
+
+ <% include('/elements/tr-select.html',
+ 'label' => 'Layout',
+ 'field' => 'cgp_skinname',
+ 'options' => [ '', '***', 'GoldFleece', 'Skin2' ],
+ 'labels' => {
+ '' => 'default (***)',
+ },
+ 'curr_value' => $svc_acct->cgp_skinname,
+ )
+ %>
+
+%#XXX pronto style
+
+ <% include('/elements/tr-select.html',
+ 'label' => 'Send read receipts',
+ 'field' => 'cgp_sendmdnmode',
+ 'options' => [ '', 'Never', 'Manually', 'Automatically' ],
+ 'labels' => {
+ '' => 'default (Automatically)',
+ },
+ 'curr_value' => $svc_acct->cgp_language,
+ )
+ %>
+
%#XXX vacation message, redirect all mail, mail rules
% } else {
- <INPUT TYPE="hidden" NAME="cgp_deletemode" VALUE="<% $svc_acct->cgp_deletemode %>">
- <INPUT TYPE="hidden" NAME="cgp_emptytrash" VALUE="<% $svc_acct->cgp_emptytrash %>">
+% for (qw( password_recover cgp_rulesallowed cgp_rpopallowed cgp_mailtoall
+% cgp_addmailtrailer
+% cgp_deletemode cgp_emptytrash cgp_language cgp_timezone
+% cgp_skinname cgp_sendmdnmode
+% ) ) {
+
+ <INPUT TYPE="hidden" NAME="<% $_ %>" VALUE="<% $svc_acct->$_() %>">
+% }
% }
diff --git a/httemplate/edit/svc_domain.cgi b/httemplate/edit/svc_domain.cgi
index 0ec91bc84..4f780d68b 100755
--- a/httemplate/edit/svc_domain.cgi
+++ b/httemplate/edit/svc_domain.cgi
@@ -178,7 +178,7 @@ Account defaults
'labels' => {
'' => 'default (No)', #No always the default?
},
- 'curr_value' => $svc_domain->acct_def_cgp_rulesallowed,
+ 'curr_value' => $svc_domain->acct_def_cgp_rulesallowed,
)
%>
@@ -225,15 +225,116 @@ Account defaults
'curr_value' => $svc_domain->acct_def_cgp_emptytrash,
)
%>
+ <% include('/elements/tr-select.html',
+ 'label' => 'Language',
+ 'field' => 'acct_def_cgp_language',
+ 'options' => [ '', qw( English Arabic Chinese Dutch French German Hebrew Italian Japanese Portuguese Russian Slovak Spanish Thai ) ],
+ 'labels' => {
+ '' => 'default (English)',
+ },
+ 'curr_value' => $svc_domain->acct_def_cgp_language,
+ )
+ %>
- <% include('/elements/tr-checkbox.html',
- 'label' =>'Password recovery',
- 'field' => 'acct_def_password_recover',
- 'curr_value' => $svc_domain->acct_def_password_recover,
- 'value' => 'Y',
+ <% include('/elements/tr-select.html',
+ 'label' => 'Time zone',
+ 'field' => 'acct_def_cgp_timezone',
+ 'options' => [
+ 'HostOS',
+ '(+0100) Algeria/Congo',
+ '(+0200) Egypt/South Africa',
+ '(+0300) Saudi Arabia',
+ '(+0400) Oman',
+ '(+0500) Pakistan',
+ '(+0600) Bangladesh',
+ '(+0700) Thailand/Vietnam',
+ '(+0800) China/Malaysia',
+ '(+0900) Japan/Korea',
+ '(+1000) Queensland',
+ '(+1100) Micronesia',
+ '(+1200) Fiji',
+ '(+1300) Tonga/Kiribati',
+ '(+1400) Christmas Islands',
+ '(-0100) Azores/Cape Verde',
+ '(-0200) Fernando de Noronha',
+ '(-0300) Argentina/Uruguay',
+ '(-0400) Venezuela/Guyana',
+ '(-0500) Haiti/Peru',
+ '(-0600) Central America',
+ '(-0700) Arisona',
+ '(-0800) Adamstown',
+ '(-0900) Marquesas Islands',
+ '(-1000) Hawaii/Tahiti',
+ '(-1100) Samoa',
+ 'Asia/Afghanistan',
+ 'Asia/India',
+ 'Asia/Iran',
+ 'Asia/Iraq',
+ 'Asia/Israel',
+ 'Asia/Jordan',
+ 'Asia/Lebanon',
+ 'Asia/Syria',
+ 'Australia/Adelaide',
+ 'Australia/East',
+ 'Australia/NorthernTerritory',
+ 'Europe/Central',
+ 'Europe/Eastern',
+ 'Europe/Moscow',
+ 'Europe/Western',
+ 'GMT (+0000)',
+ 'Newfoundland',
+ 'NewZealand/Auckland',
+ 'NorthAmerica/Alaska',
+ 'NorthAmerica/Atlantic',
+ 'NorthAmerica/Central',
+ 'NorthAmerica/Eastern',
+ 'NorthAmerica/Mountain',
+ 'NorthAmerica/Pacific',
+ 'Russia/Ekaterinburg',
+ 'Russia/Irkutsk',
+ 'Russia/Kamchatka',
+ 'Russia/Krasnoyarsk',
+ 'Russia/Magadan',
+ 'Russia/Novosibirsk',
+ 'Russia/Vladivostok',
+ 'Russia/Yakutsk',
+ 'SouthAmerica/Brasil',
+ 'SouthAmerica/Chile',
+ 'SouthAmerica/Paraguay',
+ ],
+ 'labels' => {
+ '' => 'default (HostOS)',
+ },
+ 'curr_value' => $svc_domain->acct_def_cgp_timezone,
+ )
+ %>
+
+ <% include('/elements/tr-select.html',
+ 'label' => 'Layout',
+ 'field' => 'acct_def_cgp_skinname',
+ 'options' => [ '', '***', 'GoldFleece', 'Skin2' ],
+ 'labels' => {
+ '' => 'default (***)',
+ },
+ 'curr_value' => $svc_domain->acct_def_cgp_skinname,
)
%>
+%#XXX pronto style
+
+ <% include('/elements/tr-select.html',
+ 'label' => 'Send read receipts',
+ 'field' => 'acct_def_cgp_sendmdnmode',
+ 'options' => [ '', 'Never', 'Manually', 'Automatically' ],
+ 'labels' => {
+ '' => 'default (Automatically)',
+ },
+ 'curr_value' => $svc_domain->acct_def_cgp_language,
+ )
+ %>
+
+% #XXX rules, archive rule, spam foldering rule(s)
+
</TABLE>
<BR>
@@ -241,7 +342,10 @@ Account defaults
% foreach my $f (qw( password_selfchange password_recover cgp_accessmodes
% quota file_quota file_maxnum file_maxsize
-% cgp_deletemode cgp_emptytrash
+% cgp_rulesallowed cgp_rpopallowed cgp_mailtoall
+% cgp_addmailtrailer
+% cgp_deletemode cgp_emptytrash cgp_language
+% cgp_timezone cgp_skinname cgp_sendmdnmode
% )) {
<INPUT TYPE="hidden" NAME="acct_def_<%$f%>" VALUE="<% $svc_domain->get("acct_def_$f") %>">
% }
diff --git a/httemplate/view/svc_acct/basics.html b/httemplate/view/svc_acct/basics.html
index f6bdede32..db7abe48b 100644
--- a/httemplate/view/svc_acct/basics.html
+++ b/httemplate/view/svc_acct/basics.html
@@ -110,7 +110,16 @@
<% include('/view/elements/tr.html', label=>'On logout remove trash',
value=>$svc_acct->cgp_emptytrash ) %>
-%#XXX language, time zone, layout, printo style, send read receipts
+ <% include('/view/elements/tr.html', label=>'Language',
+ value=>$svc_acct->cgp_language || 'default (English)' ) %>
+ <% include('/view/elements/tr.html', label=>'Time zone',
+ value=>$svc_acct->cgp_timezone || 'default (HostOS)' ) %>
+ <% include('/view/elements/tr.html', label=>'Layout',
+ value=>$svc_acct->cgp_skinname || 'default (***)' ) %>
+%#XXX pronto style
+ <% include('/view/elements/tr.html', label=>'Send read receipts',
+ value=>$svc_acct->cgp_sendmdnmode ) %>
+
%#XXX vacation message, redirect all mail, mail rules
% }
diff --git a/httemplate/view/svc_domain/acct_defaults.html b/httemplate/view/svc_domain/acct_defaults.html
index 01cc282fb..635158002 100644
--- a/httemplate/view/svc_domain/acct_defaults.html
+++ b/httemplate/view/svc_domain/acct_defaults.html
@@ -85,6 +85,35 @@
)
%>
+ <% include('/view/elements/tr.html',
+ label=>'Language',
+ value=>$svc_domain->acct_def_cgp_language || 'default (English)'
+ )
+ %>
+
+ <% include('/view/elements/tr.html',
+ label=>'Time zone',
+ value=>$svc_domain->acct_def_cgp_timezone || 'default (HostOS)'
+ )
+ %>
+
+ <% include('/view/elements/tr.html',
+ label=>'Layout',
+ value=>$svc_domain->acct_def_cgp_skinname || 'default (***)'
+ )
+ %>
+
+%#XXX pronto style
+
+ <% include('/view/elements/tr.html',
+ label=>'Send read receipts',
+ value=>$svc_domain->acct_def_cgp_sendmdnmode
+ )
+ %>
+
+%# mail
+%#XXX rules, archive rule, spam foldering rule(s)
+
</TABLE></TD></TR></TABLE>
% }