瀏覽代碼

修改计划下拉

luowei 2 年之前
父節點
當前提交
252627a54f

+ 15 - 13
soc-modules/soc-modules-core/src/main/java/com/xunmei/core/access/service/impl/TMonitoringRetrievalPlanServiceImpl.java

@@ -99,22 +99,24 @@ public class TMonitoringRetrievalPlanServiceImpl extends ServiceImpl<TMonitoring
         if (tMonitoringRetrievalPlan.getParams().get("beginTime") != null && tMonitoringRetrievalPlan.getParams().get("endTime") != null) {
             query.between("create_time", tMonitoringRetrievalPlan.getParams().get("beginTime"), tMonitoringRetrievalPlan.getParams().get("endTime"));
         }
+        query.orderByAsc("parent_id");
         query.orderByDesc("create_time");
         //获取数据
-        query.isNull(PARENT_ID);
+       // query.isNull(PARENT_ID);
         page = tMonitoringRetrievalPlanMapper.selectPage(page, query);
-        List<TMonitoringRetrievalPlan> records = page.getRecords();
-        List<TMonitoringRetrievalPlanVO> tMonitoringRetrievalPlanVOS = BeanHelper.copyProperties(records, TMonitoringRetrievalPlanVO.class);
-        for (TMonitoringRetrievalPlanVO monitoringRetrievalPlan : tMonitoringRetrievalPlanVOS) {
-            dealData(monitoringRetrievalPlan, tMonitoringRetrievalPlanVOS);
-        }
-        //抓换为TableDataInfo适配前端
-        TableDataInfo<TMonitoringRetrievalPlanVO> tableDataInfo = new TableDataInfo();
-        tableDataInfo.setMsg("操作成功");
-        tableDataInfo.setCode(200);
-        tableDataInfo.setTotal(page.getTotal());
-        tableDataInfo.setRows(tMonitoringRetrievalPlanVOS);
-        return tableDataInfo;
+//        List<TMonitoringRetrievalPlan> records = page.getRecords();
+//        List<TMonitoringRetrievalPlanVO> tMonitoringRetrievalPlanVOS = BeanHelper.copyProperties(records, TMonitoringRetrievalPlanVO.class);
+//        for (TMonitoringRetrievalPlanVO monitoringRetrievalPlan : tMonitoringRetrievalPlanVOS) {
+//            dealData(monitoringRetrievalPlan, tMonitoringRetrievalPlanVOS);
+//        }
+//        //抓换为TableDataInfo适配前端
+//        TableDataInfo<TMonitoringRetrievalPlanVO> tableDataInfo = new TableDataInfo();
+//        tableDataInfo.setMsg("操作成功");
+//        tableDataInfo.setCode(200);
+//        tableDataInfo.setTotal(page.getTotal());
+//        tableDataInfo.setRows(tMonitoringRetrievalPlanVOS);
+       // return tableDataInfo;
+        return TableDataInfo.build(page);
     }
 
     private void dealData(TMonitoringRetrievalPlanVO record, List<TMonitoringRetrievalPlanVO> records) {