|
@@ -140,7 +140,7 @@ module.exports = app => {
|
|
|
|
|
|
const type = msgInfo ? msgInfo.type : ctx.request.query.type ? parseInt(ctx.request.query.type) : 1;
|
|
|
|
|
|
- if (msgInfo && msgInfo.project_id !== ctx.session.sessionProject.id) {
|
|
|
+ if (msgInfo && msgInfo.type === 1 && msgInfo.project_id !== ctx.session.sessionProject.id) {
|
|
|
throw '非该项目通知无权查看';
|
|
|
}
|
|
|
|
|
@@ -239,7 +239,7 @@ module.exports = app => {
|
|
|
const url = ctx.protocol + '://' + ctx.host + '/wap/dashboard/msg/' + msgInfo.id;
|
|
|
const msgData = {
|
|
|
thing21: {
|
|
|
- value: projectData.code,
|
|
|
+ value: ctx.helper.contentChange(projectData.name),
|
|
|
},
|
|
|
thing2: {
|
|
|
value: ctx.helper.contentChange(msgInfo.title),
|
|
@@ -252,7 +252,7 @@ module.exports = app => {
|
|
|
},
|
|
|
};
|
|
|
for (const wx of wechats) {
|
|
|
- await app.wechat.api.sendTemplate(wx.wx_openid, templateId, url, '', msgData);
|
|
|
+ const result = await app.wechat.api.sendTemplate(wx.wx_openid, templateId, url, '', msgData);
|
|
|
}
|
|
|
}
|
|
|
}
|