Browse Source

修复协同审批待办页bug

ellisran 1 year ago
parent
commit
6a0b1a4301
2 changed files with 3 additions and 2 deletions
  1. 2 1
      app/service/stage_audit_ass.js
  2. 1 1
      app/view/dashboard/index.ejs

+ 2 - 1
app/service/stage_audit_ass.js

@@ -49,7 +49,7 @@ module.exports = app => {
                 const index = accountAssData.findIndex(x => { return x.tid === as.tid && x.user_id === as.user_id; });
                 if (index >= 0) {
                     accountAssData.splice(index, 1);
-                    if (as.confirm === 0) result.push(as);
+                    result.push(as);
                 }
             }
             result.push(...accountAssData);
@@ -63,6 +63,7 @@ module.exports = app => {
                         r.tender_name = t.name;
                         r.sstatus = s.status;
                         r.sorder = s.order;
+                        if (r.times && r.times === s.times && r.confirm === 1) continue;
                         if (s && s.status === auditConst.stage.status.checkNo && s.user_id === r.user_id) {
                             const lastAudit = await this.ctx.service.stageAudit.getLastestAuditor(s.id, s.times - 1, auditConst.stage.status.checkNo);
                             r.begin_time = lastAudit ? lastAudit.end_time : s.in_time;

+ 1 - 1
app/view/dashboard/index.ejs

@@ -48,7 +48,7 @@
                                     <% if (auditRevise.length !== 0) { %>
                                     <option value="4">台账修订(<%- auditRevise.length %>)</option>
                                     <% } %>
-                                    <% if (auditStages.length !== 0) { %>
+                                    <% if (auditStages.length !== 0 || auditStageAss.length !== 0) { %>
                                     <option value="2">计量审批(<%- (auditStages.length + auditStageAss.length) %>)</option>
                                     <% } %>
                                     <% if (auditChanges.length !== 0) { %>