mirror of
https://github.com/cnodejs/nodeclub.git
synced 2026-01-18 15:13:13 +00:00
关闭邮件通知功能
This commit is contained in:
parent
384ccf8a8c
commit
7fddd22ff3
@ -120,8 +120,6 @@ exports.setting = function (req, res, next) {
|
||||
profile: data.profile,
|
||||
weibo: data.weibo,
|
||||
githubUsername: data.github || data.githubUsername,
|
||||
receive_at_mail: data.receive_at_mail,
|
||||
receive_reply_mail: data.receive_reply_mail
|
||||
};
|
||||
if (isSuccess) {
|
||||
data2.success = msg;
|
||||
@ -157,8 +155,6 @@ exports.setting = function (req, res, next) {
|
||||
if (github.indexOf('@') === 0) {
|
||||
github = github.slice(1);
|
||||
}
|
||||
var receive_at_mail = req.body.receive_at_mail === 'on';
|
||||
var receive_reply_mail = req.body.receive_reply_mail === 'on';
|
||||
|
||||
if (url !== '') {
|
||||
try {
|
||||
@ -194,8 +190,6 @@ exports.setting = function (req, res, next) {
|
||||
user.profile = profile;
|
||||
user.weibo = weibo;
|
||||
user.githubUsername = github;
|
||||
user.receive_at_mail = receive_at_mail;
|
||||
user.receive_reply_mail = receive_reply_mail;
|
||||
user.save(function (err) {
|
||||
if (err) {
|
||||
return next(err);
|
||||
|
||||
@ -81,6 +81,8 @@ exports.sendResetPassMail = function (who, token, name) {
|
||||
* @param {Object} msg 发送的消息对象
|
||||
*/
|
||||
exports.sendReplyMail = function (who, msg) {
|
||||
return; // !!!关闭发送通知邮件
|
||||
|
||||
var from = util.format('%s <%s>', config.name, config.mail_opts.auth.user);
|
||||
var to = who;
|
||||
var subject = config.name + ' 新消息';
|
||||
@ -110,10 +112,13 @@ exports.sendReplyMail = function (who, msg) {
|
||||
* @param {Object} msg 发送的消息对象
|
||||
*/
|
||||
exports.sendAtMail = function (who, msg) {
|
||||
return; // !!!关闭发送at通知邮件
|
||||
|
||||
|
||||
if (!msg.topic || !msg.reply) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
var from = util.format('%s <%s>', config.name, config.mail_opts.auth.user);
|
||||
var to = who;
|
||||
var subject = config.name + ' 新消息';
|
||||
|
||||
@ -96,27 +96,6 @@
|
||||
<% } %>
|
||||
</div>
|
||||
</div>
|
||||
<div class='control-group'>
|
||||
<label class='control-label' for='receive_at_msg'>邮件提醒</label>
|
||||
<div class='controls'>
|
||||
<label class='checkbox'>
|
||||
<% if(locals.receive_at_mail){ %>
|
||||
<input type='checkbox' name='receive_at_mail' checked='checked' />
|
||||
<% }else{ %>
|
||||
<input type='checkbox' name='receive_at_mail' />
|
||||
<% } %>
|
||||
我被别人@时
|
||||
</label>
|
||||
<label class='checkbox'>
|
||||
<% if (locals.receive_reply_mail){ %>
|
||||
<input type='checkbox' name='receive_reply_mail' checked='checked' />
|
||||
<% }else{ %>
|
||||
<input type='checkbox' name='receive_reply_mail' />
|
||||
<% } %>
|
||||
我的话题收到回复时
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<input type='hidden' id='action' name='action' value='change_setting' />
|
||||
<input type='hidden' name='_csrf' value='<%= csrf %>' />
|
||||
<div class='form-actions'>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user