Commit 30664e65 authored by 竹天卫's avatar 竹天卫

统计 设备

parent ae8e7e00
package cn.wise.sc.acquisition.business.controller;
import cn.wise.im.common.http.R;
import cn.wise.sc.acquisition.business.constant.Rcode;
import cn.wise.sc.acquisition.business.service.IDataStatisticsService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
......@@ -39,12 +40,13 @@ public class DataStatisticsController {
})
@GetMapping("/countByPhoto")
public R countByPhoto(Integer type, String TruckID, Integer cycle, String startDate, String endDate) {
Rcode.NOT_PARAM.assertNotNull(type);
if(type == 1){
return dataStatisticsService.countByPhoto(TruckID, cycle, startDate, endDate);
}else if(type == 2){
return dataStatisticsService.countByTable(TruckID, cycle, startDate, endDate);
}else{
return R.fail(400, "参数错误");
return R.fail(402, "参数错误");
}
}
......
......@@ -57,7 +57,6 @@
<if test="params.startDate == null and params.endDate == null">
and datediff(week, tw.Rq,getdate())=0
</if>
group by tw.Rq
</select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment