whycxzp
2021-03-05 e7a7b634352f684085bb6eea34b331fc069ff44d
src/main/java/com/whyc/controller/CentralMonitorSysSTController.java
@@ -1,6 +1,8 @@
package com.whyc.controller;
import com.github.pagehelper.PageInfo;
import com.whyc.dto.Response;
import com.whyc.pojo.CentralMonitorSysRT;
import com.whyc.pojo.CentralMonitorSysST;
import com.whyc.service.CentralMonitorSysRTService;
import com.whyc.service.CentralMonitorSysSTService;
@@ -27,6 +29,16 @@
        return service.getInfoByDevId(devId);
    }
    /**
     * ======History======
     * 历史查询时,因为历史记录是按照日期分表的,如果查询所有的日期表(union)后再分页,会导致速度极慢,故查询按照单个日期查询
     * TODO 待确定是否需要加上日期
     * */
    @GetMapping("history/all")
    @ApiOperation(value = "查询历史记录")
    public Response<PageInfo<CentralMonitorSysST>> getHistory(@RequestParam int pageNum, int pageSize, int devId){
        return service.getHistory(pageNum,pageSize,devId);
    }
}