| | |
| | | package cn.gistack.nky.feign; |
| | | |
| | | import cn.gistack.nky.entity.AlarmGet; |
| | | import cn.gistack.nky.fegin.INkyClient; |
| | | import cn.gistack.nky.service.IAlarmGetService; |
| | | import cn.gistack.nky.service.IArimaPredictService; |
| | | import cn.gistack.nky.service.IHstPredictService; |
| | | import cn.gistack.nky.service.INkyService; |
| | | import cn.gistack.nky.vo.AlarmGetVO; |
| | | import cn.gistack.nky.vo.PageVO; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tenant.annotation.NonDS; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | import springfox.documentation.annotations.ApiIgnore; |
| | | |
| | | import java.util.List; |
| | | |
| | | @NonDS |
| | | @ApiIgnore |
| | |
| | | public void alarmGetData(String type) { |
| | | alarmGetService.alarmGetData(type); |
| | | } |
| | | |
| | | @Override |
| | | @PostMapping(GET_ALARM_DETAIL) |
| | | public List<AlarmGetVO> getAlarmDetail(AlarmGetVO alarmGet) { |
| | | return alarmGetService.getAlarmDetail(alarmGet); |
| | | } |
| | | |
| | | @Override |
| | | @PostMapping(GET_ALARM_DETAIL_PAGE) |
| | | public PageVO<AlarmGetVO> getAlarmDetailPage(Integer current, Integer size, AlarmGetVO alarmGet) { |
| | | Query query = new Query(); |
| | | query.setCurrent(current); |
| | | query.setSize(size); |
| | | IPage<AlarmGetVO> alarmDetailPage = alarmGetService.getAlarmDetailPage(Condition.getPage(query), alarmGet); |
| | | |
| | | PageVO<AlarmGetVO> pageVO = new PageVO(); |
| | | |
| | | pageVO.setData(alarmDetailPage.getRecords()); |
| | | pageVO.setTotal(alarmDetailPage.getTotal()); |
| | | pageVO.setCurrent(alarmDetailPage.getCurrent()); |
| | | pageVO.setSize(alarmDetailPage.getSize()); |
| | | |
| | | return pageVO; |
| | | } |
| | | } |