mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-21 05:44:07 -07:00
WEB / MAIL. Updated mail acc options for different IMAP and SMTP configurations
This commit is contained in:
parent
45d5e885a4
commit
5c30f7c2d2
5 changed files with 194 additions and 130 deletions
|
@ -107,11 +107,43 @@ $(document).ready(function() {
|
|||
else
|
||||
$('#v_password').text(Array($(this).val().length+1).join('*'));
|
||||
});
|
||||
|
||||
|
||||
$('.toggle-psw-visibility-icon').click(function(){
|
||||
if($('input[name=v_password]').attr('type') == 'text')
|
||||
$('#v_password').text($('input[name=v_password]').val());
|
||||
else
|
||||
$('#v_password').text(Array($('input[name=v_password]').val().length+1).join('*'));
|
||||
});
|
||||
});
|
||||
|
||||
$('#mail_configuration').change(function(evt){
|
||||
var opt = $(evt.target).find('option:selected');
|
||||
|
||||
switch(opt.attr('v_type')){
|
||||
case 'hostname':
|
||||
$('#td_imap_hostname').html(opt.attr('domain'));
|
||||
$('#td_smtp_hostname').html(opt.attr('domain'));
|
||||
break;
|
||||
case 'starttls':
|
||||
$('#td_imap_port').html('143');
|
||||
$('#td_imap_encryption').html('STARTTLS');
|
||||
$('#td_smtp_port').html('587');
|
||||
$('#td_smtp_encryption').html('STARTTLS');
|
||||
break;
|
||||
case 'ssl':
|
||||
$('#td_imap_port').html('993');
|
||||
$('#td_imap_encryption').html('SSL');
|
||||
$('#td_smtp_port').html('465');
|
||||
$('#td_smtp_encryption').html('SSL');
|
||||
break;
|
||||
case 'no_encription':
|
||||
$('#td_imap_hostname').html(opt.attr('domain'));
|
||||
$('#td_smtp_hostname').html(opt.attr('domain'));
|
||||
|
||||
$('#td_imap_port').html('143');
|
||||
$('#td_imap_encryption').html(opt.attr('no_encription'));
|
||||
$('#td_smtp_port').html('25');
|
||||
$('#td_smtp_encryption').html(opt.attr('no_encription'));
|
||||
break;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue