Browse Source

修复协同审批待办页bug

ellisran 1 năm trước cách đây
mục cha
commit
a62e9d6cae
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      app/service/stage_audit_ass.js

+ 2 - 2
app/service/stage_audit_ass.js

@@ -42,14 +42,14 @@ module.exports = app => {
 
         async getAuditStageAss(ass_user_id) {
             // 找出待上报或待审批的协同字段
-            const accountStageAssData = await this.getAllDataByCondition({ where: { ass_user_id, confirm: 0 } });
+            const accountStageAssData = await this.getAllDataByCondition({ where: { ass_user_id } });
             const result = [];
             const accountAssData = await this.ctx.service.auditAss.getAllDataByCondition({ where: { ass_user_id } });
             for (const as of accountStageAssData) {
                 const index = accountAssData.findIndex(x => { return x.tid === as.tid && x.user_id === as.user_id; });
                 if (index >= 0) {
                     accountAssData.splice(index, 1);
-                    result.push(as);
+                    if (as.confirm === 0) result.push(as);
                 }
             }
             result.push(...accountAssData);