MaiXinRong 3 тижнів тому
батько
коміт
ca8718efb1
1 змінених файлів з 1 додано та 1 видалено
  1. 1 1
      app/controller/measure_controller.js

+ 1 - 1
app/controller/measure_controller.js

@@ -110,7 +110,7 @@ module.exports = app => {
                 }
                 const stages = await ctx.service.stage.getAllDataByCondition({ where: { tid: ctx.tender.id }});
                 const unCompleteStageCount = stages.filter(s => { return s.status !== auditConst.status.checked; }).length;
-                if (unCompleteStageCount.length > 0) {
+                if (unCompleteStageCount > 0) {
                     if (ctx.subProject.page_show.openMultiStageCalc) {
                         if (ctx.tender.info.calc_type === 'tp') throw `【总价合同】不允许新增下一期,请联系管理员`;
                         if (ctx.subProject.page_show.correctCalcContractTp) throw `【反算本期合同计量】不允许新增下一期,请联系管理员`;