| | |
| | | import com.auth0.jwt.exceptions.JWTDecodeException; |
| | | import com.moral.common.bean.ResultBean; |
| | | import com.moral.common.exception.WebAuthException; |
| | | import com.moral.common.util.BeanUtils; |
| | | import com.moral.common.util.ParameterUtils; |
| | | import com.moral.common.util.RedisHashUtil; |
| | | import com.moral.common.util.WebTokenUtils; |
| | | import com.moral.common.util.*; |
| | | import com.moral.common.webAnno.UserLoginToken; |
| | | import com.moral.entity.AreaNames; |
| | | import com.moral.entity.MonitorPoint; |
| | | import com.moral.entity.Organization; |
| | | import com.moral.service.*; |
| | | import com.moral.util.LatLngTransformation; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import jdk.nashorn.internal.runtime.logging.Logger; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | |
| | | RedisHashUtil redisHashUtil; |
| | | @Resource |
| | | HistoryMinutelyService historyMinutelyService; |
| | | @Resource |
| | | MonitorPointService monitorPointService; |
| | | |
| | | @UserLoginToken |
| | | @GetMapping("test") |
| | |
| | | |
| | | |
| | | @UserLoginToken |
| | | @PostMapping("report_avg_datas") |
| | | public ResultBean<List<Map<String, Object>>> getMonitorPointOrDeviceAvgData(HttpServletRequest request,@RequestBody Map<String, Object> parameters) |
| | | @GetMapping("report_avg_datas") |
| | | public ResultBean<List<Map<String, Object>>> getMonitorPointOrDeviceAvgData(HttpServletRequest request) |
| | | throws Exception { |
| | | Map<String, Object> parameters = WebUtils.getParametersStartingWith(request, null); |
| | | //该方法用于判断时间是具体到年月日 |
| | | ParameterUtils.getTimeType4Time(parameters); |
| | | Object sensorKey = parameters.remove("sensorKey"); |
| | |
| | | } |
| | | return new ResultBean<List<Map<String, Object>>>(list); |
| | | } |
| | | |
| | | @UserLoginToken |
| | | @GetMapping("monitorpoints-devices") |
| | | public ResultBean<List<MonitorPoint>> getMonitorPointsAndDevicesByRegion(HttpServletRequest request) |
| | | throws Exception { |
| | | Map<String, Object> parameters = WebUtils.getParametersStartingWith(request, null); |
| | | List<MonitorPoint> monitorPoints = monitorPointService.getMonitorPointsAndDevicesByRegion(parameters); |
| | | return new ResultBean<List<MonitorPoint>>(monitorPoints); |
| | | } |
| | | } |