5ea65127 康伟

kangwei: 水务公司生产运营工作进度统计功能开发-后端

1 个父辈 e8d2ae8c
......@@ -31,7 +31,7 @@ import java.util.List;
public class WorkAnalysisController {
@ApiOperation(value = "工作进度统计", notes = "工作进度统计 timeType = 1 表示月份,timeType=2 表示年")
@ApiOperation(value = "工作进度列表", notes = "工作进度列表 timeType = 1 表示月份,timeType=2 表示年")
@GetMapping("/analysisByWorkProgress")
public Result<List<WorkProgressVO>> analysisByWorkProgress(@RequestParam(defaultValue = "1") Integer timeType, String startTime, String endTime) {
Result<List<WorkProgressVO>> result = new Result<>();
......@@ -56,7 +56,7 @@ public class WorkAnalysisController {
return result;
}
@ApiOperation(value = "工作进度统计-数量", notes = "工作进度统计 timeType = 1 表示月份,timeType=2 表示年")
@ApiOperation(value = "工作进度统计-数量统计", notes = "工作进度-数量统计 timeType = 1 表示月份,timeType=2 表示年")
@GetMapping("/analysisTotalByWorkProgress")
public Result<WorkProgressVO> analysisTotalByWorkProgress(@RequestParam(defaultValue = "1") Integer timeType, String startTime, String endTime) {
Result<WorkProgressVO> result = new Result<>();
......@@ -86,7 +86,7 @@ public class WorkAnalysisController {
}
@ApiOperation(value = "安全管理进度统计", notes = "安全管理进度统计 timeType = 1 表示月份,timeType=2 表示年")
@ApiOperation(value = "安全管理进度-数据列表", notes = "安全管理进度-数据列表 timeType = 1 表示月份,timeType=2 表示年")
@GetMapping("/analysisBySafeProgress")
public List<SafeProgressVO> analysisBySafeProgress(@RequestParam(defaultValue = "1") Integer timeType, String startTime, String endTime) {
JdbcTemplate jdbcTemplate = (JdbcTemplate) SpringContextUtils.getBean("master");
......@@ -105,7 +105,7 @@ public class WorkAnalysisController {
return dataList;
}
@ApiOperation(value = "安全管理进度统计-数量", notes = "安全管理进度统计 timeType = 1 表示月份,timeType=2 表示年")
@ApiOperation(value = "安全管理进度统计-数量统计", notes = "安全管理进度-数量统计 timeType = 1 表示月份,timeType=2 表示年")
@GetMapping("/analysisTotalBySafeProgress")
public SafeProgressVO analysisTotalBySafeProgress(@RequestParam(defaultValue = "1") Integer timeType, String startTime, String endTime) {
String departIds = null;//DAY(LAST_DAY('"+startTime+"'))
......@@ -134,10 +134,13 @@ public class WorkAnalysisController {
userIds = "''";
}
String sql = "";
//会议任务
sql += " left join( select depart_id , count(1) 'count' from ajh_meeting_send where meet_status =2 and meet_end_time >='"+startTime+"' and meet_end_time <= '"+endTime+"' group by depart_id )aaa on aaa.depart_id = d.id ";
sql += " left join (select depart_id , count(1) 'count' from ajh_meeting_send where meet_id in (select id from ajh_meeting where end_time >='"+startTime+"' and end_time <= '"+endTime+"') group by depart_id ) bbb on bbb.depart_id = d.id ";
// 考试任务
sql += " left join (select depart_id,count(user_id) 'count' from edu_user_paper where DATE_FORMAT(end_time,'%Y-%m-%d') >='"+startTime+"' and end_time <= '"+endTime+"' and user_id in("+userIds+") group by depart_id )ccc on ccc.depart_id = d.id";
sql += " left join ( select dep_id,count(user_id) 'count' from sys_user_depart where user_id in("+userIds+") group by dep_id )ddd on ddd.dep_id = d.id";
//风险排查任务
sql += " left join ( select depart_id ,count(id) 'count' from danger_inspection_record where status = '2' and end_date >= '"+startTime+" 00:00:00' and end_date <='"+endTime+" 23:59:59' group by depart_id ) eee on eee.depart_id = d.id ";
sql += " left join( select sum( (DATEDIFF('"+endTime+"', '"+startTime+"') +1)*24/ dlm.frequency ) 'count' , dlm.depart_id from danger_level_manage dlm where dlm.frequency IS NOT NULL and frequency <> '' ) fff on fff.depart_id = d.id ";
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!