package cn.com.goldenwater.dcproj.controller; import cn.com.goldenwater.core.web.BaseController; import cn.com.goldenwater.core.web.BaseResponse; import cn.com.goldenwater.dcproj.dto.BisInspTaskDthDayDto; import cn.com.goldenwater.dcproj.model.TacPawpRgstr; import cn.com.goldenwater.dcproj.service.IndexTotalService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.cache.annotation.Cacheable; import org.springframework.web.bind.annotation.*; import java.util.List; import java.util.Map; /** * @author */ @Api(value = "数字看板", tags = "数字看板") @RestController @RequestMapping("/index/total") public class JcIndexTotalController extends BaseController { @Autowired private IndexTotalService indexTotalService; @ApiOperation(value = "数字看板(稽察)") @GetMapping(value = "/jicha") public BaseResponse> indexOfJc(BisInspTaskDthDayDto bisInspTaskDthDayDto) { bisInspTaskDthDayDto.setOrgId(getCurrentOrgId()); return buildSuccessResponse(indexTotalService.totalAllOfJicha(bisInspTaskDthDayDto)); } @ApiOperation(value = "按 工程分类 统计问题个数(稽察)") @GetMapping(value = "/engType/{timeType}") public BaseResponse>> statisticsByEngType(@PathVariable String timeType, BisInspTaskDthDayDto bisInspTaskDthDayDto) { bisInspTaskDthDayDto.setOrgId(getCurrentOrgId()); bisInspTaskDthDayDto.setTimeType(timeType); return buildSuccessResponse(indexTotalService.statisticsByEngType(bisInspTaskDthDayDto)); } @ApiOperation(value = "按 责任主体 统计问题个数(稽察)") @GetMapping(value = "/resub/{timeType}") public BaseResponse>> statisticsByResubType(@PathVariable String timeType, BisInspTaskDthDayDto bisInspTaskDthDayDto) { bisInspTaskDthDayDto.setOrgId(getCurrentOrgId()); bisInspTaskDthDayDto.setTimeType(timeType); return buildSuccessResponse(indexTotalService.statisticsByResubType(bisInspTaskDthDayDto)); } @ApiOperation(value = "按 稽察状态 统计对象数量(稽察)") @GetMapping(value = "/objSizeRant") public BaseResponse> statisticsObjSizeOfJc(@RequestParam(required = false) String timeType, @RequestParam(required = false) String objType) { BisInspTaskDthDayDto bisInspTaskDthDayDto = new BisInspTaskDthDayDto(); bisInspTaskDthDayDto.setOrgId(getCurrentOrgId()); bisInspTaskDthDayDto.setTimeType(timeType); if (StringUtils.isNotBlank(objType)) { bisInspTaskDthDayDto.setObjType(String.valueOf(Integer.parseInt(objType))); } return buildSuccessResponse(indexTotalService.getObjSize(bisInspTaskDthDayDto)); } // @ApiOperation(value = "按 稽察状态 统计对象经纬度(稽察)") // @GetMapping(value = "/jicha/lnglat") // public BaseResponse>> statisticsObjLnglatOfJc(@RequestParam(required = false) String timeType) { // BisInspTaskDthDayDto bisInspTaskDthDayDto = new BisInspTaskDthDayDto(); // bisInspTaskDthDayDto.setOrgId(getCurrentOrgId()); // bisInspTaskDthDayDto.setTimeType(timeType); // return buildSuccessResponse(indexTotalService.getJiChaLnglat(bisInspTaskDthDayDto)); // } }