邮件:循环邮件优化
This commit is contained in:
@@ -104,17 +104,7 @@ export class GmHandler {
|
||||
await f.pushToUsers();
|
||||
// await f.saveRecord(uid);
|
||||
}
|
||||
let sendTime = '';
|
||||
if(isPass) {
|
||||
if(timeType == MAIL_TIME_TYPE.IMMEDIATE) {
|
||||
sendTime = moment().format('YYYY-MM-DD HH:mm:ss');
|
||||
} else if (timeType == MAIL_TIME_TYPE.DELAY) {
|
||||
sendTime = moment(startTime * 1000).format('YYYY-MM-DD HH:mm:ss');
|
||||
} else if (timeType == MAIL_TIME_TYPE.CIRCLE) {
|
||||
sendTime = (circleDay == 0?'每天': '每周'+circleDay) + ' ' + circleHour;
|
||||
}
|
||||
}
|
||||
await GMMailModel.updateMailById(id, { status: isPass? GM_MAIL_STATUS.PASS: GM_MAIL_STATUS.NOT_PASS, viewAt: new Date(), viewBy: uid, sendTime }, uid);
|
||||
await GMMailModel.updateMailById(id, { status: isPass? GM_MAIL_STATUS.PASS: GM_MAIL_STATUS.NOT_PASS, viewAt: new Date(), viewBy: uid }, uid);
|
||||
return resResult(STATUS.SUCCESS);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user