|
@@ -77,7 +77,9 @@ class TrainplanService extends CrudService {
|
|
|
let date = new Date();
|
|
|
date = moment(date).format('YYYY-MM-DD HH:mm:ss');
|
|
|
const remark = '感谢您的使用';
|
|
|
- this.ctx.service.weixin.sendTemplateMsg(this.ctx.app.config.REVIEW_TEMPLATE_ID, openid, '您有一个新的通知', detail, date, remark);
|
|
|
+ if (openid) {
|
|
|
+ this.ctx.service.weixin.sendTemplateMsg(this.ctx.app.config.REVIEW_TEMPLATE_ID, openid, '您有一个新的通知', detail, date, remark);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
return await trainplan.save();
|