MaiXinRong 3 年之前
父節點
當前提交
bdd9476701
共有 1 個文件被更改,包括 3 次插入2 次删除
  1. 3 2
      app/controller/stage_controller.js

+ 3 - 2
app/controller/stage_controller.js

@@ -283,8 +283,9 @@ module.exports = app => {
         async _getStagePosData(ctx, posColumn) {
         async _getStagePosData(ctx, posColumn) {
             let curStageData,
             let curStageData,
                 preStageData;
                 preStageData;
-            // const posData = await ctx.service.pos.getAllDataByCondition({ where: { tid: ctx.tender.id } });
-            const posData = await ctx.service.pos.getAllDataByCondition({ columns: posColumn, where: { tid: ctx.tender.id } });
+            const posData =  ctx.stage.ledgerHis
+                ? await ctx.service.ledger.loadDataFromOss(ctx.tender.id, ctx.stage.ledgerHis.pos_file)
+                : await ctx.service.pos.getAllDataByCondition({ columns: posColumn, where: { tid: ctx.tender.id } });
             // 根据当前人,或指定对象查询数据
             // 根据当前人,或指定对象查询数据
             // console.time('cur');
             // console.time('cur');
             if (ctx.stage.readOnly) {
             if (ctx.stage.readOnly) {