瀏覽代碼

Merge branch 'master' of http://192.168.1.41:3000/maixinrong/Calculation

MaiXinRong 5 年之前
父節點
當前提交
5787e4e472
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/service/revise_audit.js

+ 1 - 1
app/service/revise_audit.js

@@ -375,7 +375,7 @@ module.exports = app => {
                 '  Left Join ' + this.ctx.service.ledgerRevise.tableName + ' As r On ra.rid = r.id' +
                 '  Left Join '+ this.ctx.service.tender.tableName +' AS t On r.tid = t.id' +
                 '  Left Join ' + this.ctx.service.projectAccount.tableName + ' As p On ra.audit_id = p.id' +
-                '  WHERE ((ra.`audit_id` = ? and ra.`status` = ?) OR' +
+                '  WHERE r.`valid` != 0 and t.`id` != null and ((ra.`audit_id` = ? and ra.`status` = ?) OR' +
                 '    (r.`uid` = ? and r.`status` = ? and ra.`status` = ? and ra.`times` = (r.`times`-1)))';
             const sqlParam = [auditorId, auditConst.status.checking, auditorId, auditConst.status.checkNo, auditConst.status.checkNo];
             return await this.db.query(sql, sqlParam);