浏览代码

进入归档stage丢失问题

TonyKang 4 年之前
父节点
当前提交
a570ed563f
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      app/controller/report_archive_controller.js

+ 3 - 1
app/controller/report_archive_controller.js

@@ -19,7 +19,7 @@ module.exports = app => {
 
         async index(ctx) {
             const tender = ctx.tender;
-            const stage = ctx.stage;
+            let stage = ctx.stage;
             let stage_id = -1;
             let stage_order = -1;
             let stage_times = -1;
@@ -53,6 +53,8 @@ module.exports = app => {
                     if (stageList[sidx].status === 3) {
                         archives = await ctx.service.rptArchive.getPrjStgArchive(tender.data.project_id, stageList[sidx].id);
                         stage_id = stageList[sidx].id;
+                        stage = stageList[sidx];
+                        ctx.stage = stageList[sidx];
                         break;
                     }
                 }