From 13b1b45ee4bab5b832ca3a1602b4c4fb6d391f86 Mon Sep 17 00:00:00 2001 From: Lukas Reschke Date: Fri, 3 Oct 2014 15:14:22 +0200 Subject: Refactor MailSettings controller - Do not store the password (fixes https://github.com/owncloud/core/issues/11385) - Refactor to AppFramework - Add unit tests Conflicts: settings/admin/controller.php --- settings/js/admin.js | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'settings/js/admin.js') diff --git a/settings/js/admin.js b/settings/js/admin.js index d8cdae9d11b..09e8a1d6916 100644 --- a/settings/js/admin.js +++ b/settings/js/admin.js @@ -103,14 +103,22 @@ $(document).ready(function(){ } }); - $('#mail_settings').change(function(){ + $('#mail_general_settings').change(function(){ OC.msg.startSaving('#mail_settings_msg'); - var post = $( "#mail_settings" ).serialize(); + var post = $( "#mail_general_settings" ).serialize(); $.post(OC.generateUrl('/settings/admin/mailsettings'), post, function(data){ OC.msg.finishedSaving('#mail_settings_msg', data); }); }); + $('#mail_credentials_settings_submit').click(function(){ + OC.msg.startSaving('#mail_settings_msg'); + var post = $( "#mail_credentials_settings" ).serialize(); + $.post(OC.generateUrl('/settings/admin/mailsettings/credentials'), post, function(data){ + OC.msg.finishedSaving('#mail_settings_msg', data); + }); + }); + $('#sendtestemail').click(function(event){ event.preventDefault(); OC.msg.startAction('#sendtestmail_msg', t('settings', 'Sending...')); -- cgit v1.2.3