| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293 |
- package com.controller;
- import com.model.pojo.RepEntity;
- import com.model.vo.configVo.*;
- import com.server.*;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.web.bind.annotation.RequestBody;
- import org.springframework.web.bind.annotation.RequestHeader;
- import org.springframework.web.bind.annotation.RequestMapping;
- import org.springframework.web.bind.annotation.RestController;
- import java.sql.SQLException;
- @RestController
- public class ShowChartsController {
- @Autowired
- ShowHistogramService showHistogramService;
- @Autowired
- ShowPieService showPieService;
- @Autowired
- ShowLineService showLineService;
- @Autowired
- ShowScatterService showScatterService;
- @Autowired
- ShowIndividualService showIndividualService;
- @Autowired
- ShowPopulationService showPopulationService;
- @Autowired
- ColumnScreenService columnScreenService;
- /*
- 展示柱状图
- */
- @CheckToken
- @RequestMapping("/showHistogram")
- public RepEntity showHistogram(@RequestHeader String token,@RequestBody HistogramConfigInfo body){
- return showHistogramService.showHistogram(body);
- }
- /*
- 展示饼图
- */
- @CheckToken
- @RequestMapping("/showPie")
- public RepEntity showPie(@RequestHeader String token,@RequestBody PieConfigInfo body){
- return showPieService.showPie(body);
- }
- /*
- 展示Line
- */
- @CheckToken
- @RequestMapping("/showLine")
- public RepEntity showLine(@RequestHeader String token,@RequestBody LineConfigInfo body){
- return showLineService.showLine(body);
- }
- /*
- showScatter
- */
- @CheckToken
- @RequestMapping("/showScatter")
- public RepEntity showScatter(@RequestHeader String token,@RequestBody ScatterConfigInfo body){
- return showScatterService.showScatter(body);
- }
- /*
- show个体统计表
- */
- @CheckToken
- @RequestMapping("/showIndividual")
- public RepEntity showIndividual(@RequestHeader String token,@RequestBody IndividualConfigInfo body){
- return showIndividualService.showIndividual(body);
- }
- /*
- show总体统计表
- */
- @CheckToken
- @RequestMapping("/showPopulation")
- public RepEntity showPopulation(@RequestHeader String token,@RequestBody PopulationInfo body) throws SQLException {
- return showPopulationService.showPopulation(body);
- }
- /*
- 展示单列数据
- */
- @CheckToken
- @RequestMapping("/showScreenData")
- public RepEntity showScreenData(@RequestHeader String token,@RequestBody ColumnScreenInfo body){
- return columnScreenService.getScreenData(body);
- }
- }
|