| | |
| | | package com.panzhihua.grid_app.api; |
| | | |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.grid.*; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.grid.EventVO; |
| | | import com.panzhihua.common.model.vos.grid.UserEventGridDataVO; |
| | | import com.panzhihua.common.utlis.ClazzUtils; |
| | | import io.swagger.annotations.Api; |
| | |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.panzhihua.common.model.dtos.grid.EventGridDataEditDTO; |
| | | //import com.panzhihua.common.model.vos.IPageVO; |
| | | import com.panzhihua.common.service.grid.GridService; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.validation.Valid; |
| | | |
| | | import com.panzhihua.common.model.vos.grid.EventGridDataDetailsVO; |
| | | import com.panzhihua.common.model.vos.grid.EventGridDataVO; |
| | | import com.panzhihua.common.model.dtos.grid.EventGridDataAddDTO; |
| | | import com.panzhihua.common.model.dtos.grid.EventGridDataDeleteDTO; |
| | | import com.panzhihua.common.model.dtos.grid.PageEventGridDataDTO; |
| | | |
| | | /** |
| | | * |
| | |
| | | @Slf4j |
| | | @RestController |
| | | @RequestMapping("/eventgriddata") |
| | | @Api(tags = {"区县/街道/社区/网格员网格数据管理 @陈东"}) |
| | | @Api(tags = {"网格数据管理 @chendong"}) |
| | | public class EventGridDataApi extends BaseController { |
| | | |
| | | @Resource |
| | |
| | | return gridService.userGrid(pageEventGridDataDTO); |
| | | } |
| | | |
| | | |
| | | //------------- |
| | | /** |
| | | * 网格数据待处理统计信息 |
| | | * @return 查找结果 |
| | | */ |
| | | @GetMapping("/myGridTodoData") |
| | | @ApiOperation(value = "网格待处理统计数据", response= UserEventGridDataVO.class) |
| | | R myTodoGridData(@Valid @ModelAttribute EventGridTodoDataDTO eventGridTodoDataDTO){ |
| | | LoginUserInfoVO loginUserInfoVO = this.getLoginUserInfo(); |
| | | eventGridTodoDataDTO.setUserId(loginUserInfoVO.getUserId()); |
| | | return gridService.getGridTodoData(eventGridTodoDataDTO); |
| | | } |
| | | |
| | | /** |
| | | * 网格数据待处理统计信息 |
| | | * @return 查找结果 |
| | | */ |
| | | @GetMapping("/myGridData") |
| | | @GetMapping("/statistics/{gridId}") |
| | | @ApiOperation(value = "网格统计数据", response= UserEventGridDataVO.class) |
| | | R myGridData(){ |
| | | R myGridData(@PathVariable("gridId") Long gridId){ |
| | | LoginUserInfoVO loginUserInfoVO = this.getLoginUserInfo(); |
| | | PageEventGridDataDTO pageEventGridDataDTO = new PageEventGridDataDTO(); |
| | | pageEventGridDataDTO.setUserId(loginUserInfoVO.getUserId()); |
| | | pageEventGridDataDTO.setType(3l); |
| | | return gridService.getGridData(pageEventGridDataDTO); |
| | | EventGridStatisticsDataDTO eventGridStatisticsDataDTO = new EventGridStatisticsDataDTO(); |
| | | eventGridStatisticsDataDTO.setUserId(loginUserInfoVO.getUserId()); |
| | | eventGridStatisticsDataDTO.setGridId(gridId); |
| | | return gridService.getGridStatisticsdData(eventGridStatisticsDataDTO); |
| | | } |
| | | |
| | | |
| | | //=== |
| | | |
| | | |
| | | /** |