huanghongfa
2021-09-02 177249c76aeea0b4bf8d8816d4994e3b445b45ce
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
package com.panzhihua.service_community.api;
 
import javax.annotation.Resource;
 
import org.springframework.web.bind.annotation.*;
 
import com.panzhihua.common.model.dtos.community.bigscreen.BigScreenEventDTO;
import com.panzhihua.common.model.dtos.community.bigscreen.BigScreenEventDetailDTO;
import com.panzhihua.common.model.vos.R;
import com.panzhihua.service_community.service.ComMngPopulationService;
 
import lombok.extern.slf4j.Slf4j;
 
@Slf4j
@RestController
@RequestMapping("/screen/")
public class BigScreenStatisticsApi {
 
    @Resource
    private ComMngPopulationService comMngPopulationService;
 
    /**
     * 首页大屏统计接口
     * 
     * @param communityId
     *            社区id
     * @return 统计结果
     */
    @GetMapping("/getScreenIndex")
    public R index(@RequestParam("communityId") Long communityId) {
        return R.ok(comMngPopulationService.getScreenIndex(communityId));
    }
 
    /**
     * 事件大屏统计接口
     * 
     * @param screenEventDTO
     *            请求参数
     * @return 统计结果
     */
    @PostMapping("/getScreenEvent")
    public R event(@RequestBody BigScreenEventDTO screenEventDTO) {
        return R.ok(comMngPopulationService.getScreenEvent(screenEventDTO));
    }
 
    /**
     * 民生大屏统计接口
     * 
     * @param communityId
     *            社区id
     * @return 统计结果
     */
    @GetMapping("/getScreenCivil")
    public R civil(@RequestParam("communityId") Long communityId) {
        return R.ok(comMngPopulationService.getScreenCivil(communityId));
    }
 
    /**
     * 获取社区网格
     *
     * @param communityId
     *            社区id
     * @return 网格数据
     */
    @GetMapping("/getScreenGirds")
    public R grids(@RequestParam("communityId") Long communityId) {
        return R.ok(comMngPopulationService.getScreenGirds(communityId));
    }
 
    /**
     * 事件大屏查询事件详情
     *
     * @param eventDetailDTO
     *            请求参数
     * @return 事件详情
     */
    @PostMapping("/getScreenEventDetail")
    public R eventDetail(@RequestBody BigScreenEventDetailDTO eventDetailDTO) {
        return R.ok(comMngPopulationService.getScreenEventDetail(eventDetailDTO));
    }
 
}