|
@@ -193,7 +193,7 @@ module.exports = app => {
|
|
|
attData[index].in_time = moment(attData[index].in_time * 1000).format('YYYY-MM-DD');
|
|
|
}
|
|
|
renderData.attData = attData;
|
|
|
- renderData.coopwd = (ctx.stage.status === auditConst.status.uncheck && ctx.session.sessionUser.accountId === ctx.stage.user_id) || (ctx.stage.status === auditConst.status.checking && ctx.stage.curAuditor && ctx.stage.curAuditor.aid === ctx.session.sessionUser.accountId);
|
|
|
+ renderData.coopwd = ((ctx.stage.status === auditConst.status.uncheck || ctx.stage.status === auditConst.status.checkNo) && ctx.session.sessionUser.accountId === ctx.stage.user_id) || (ctx.stage.status === auditConst.status.checking && ctx.stage.curAuditor && ctx.stage.curAuditor.aid === ctx.session.sessionUser.accountId);
|
|
|
await this.layout('stage/index.ejs', renderData, 'stage/modal.ejs');
|
|
|
} catch (err) {
|
|
|
this.log(err);
|
|
@@ -330,7 +330,12 @@ module.exports = app => {
|
|
|
responseData.data.tags = await ctx.service.ledgerTag.getDatas(ctx.tender.id, ctx.stage.id);
|
|
|
break;
|
|
|
case 'cooperation':
|
|
|
- const uid = ctx.stage.curAuditor ? ctx.stage.curAuditor.aid : ctx.stage.status === auditConst.status.uncheck ? ctx.session.sessionUser.accountId : null;
|
|
|
+ const uid = ctx.stage.curAuditor ?
|
|
|
+ ctx.stage.curAuditor.aid :
|
|
|
+ (ctx.stage.status === auditConst.status.uncheck ||
|
|
|
+ (ctx.stage.status === auditConst.status.checkNo && ctx.stage.user_id === ctx.session.sessionUser.accountId) ?
|
|
|
+ ctx.stage.user_id : (ctx.stage.status === auditConst.status.checkNo && ctx.stage.user_id !== ctx.session.sessionUser.accountId) ?
|
|
|
+ ctx.session.sessionUser.accountId : null);
|
|
|
responseData.data.cooperation = uid !== null ? await ctx.service.ledgerCooperation.getValidData(
|
|
|
ctx.tender.id, uid) : [];
|
|
|
// responseData.data.cooperationPwd = uid !== null ? await ctx.service.cooperationPwd.getValidData(ctx.tender.id, uid) : [];
|