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 lombok.AllArgsConstructor;
|
import lombok.extern.slf4j.Slf4j;
|
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
|
@RestController
|
@AllArgsConstructor
|
@Slf4j
|
public class NkyClientImpl implements INkyClient {
|
|
private final INkyService nkyService;
|
private final IArimaPredictService arimaPredictService;
|
private final IHstPredictService hstPredictService;
|
private final IAlarmGetService alarmGetService;
|
|
|
@Override
|
@GetMapping(GET_ARIMA_DATA)
|
public void arimaQueryData(String type) {
|
arimaPredictService.getData(type);
|
}
|
|
@Override
|
@GetMapping(PREDICT_ARIMA_DATA)
|
public void arimaPredictData(String type) {
|
arimaPredictService.predictData(type);
|
}
|
|
@Override
|
@GetMapping(GET_HST_DATA)
|
public void hstQueryData(String type) {
|
hstPredictService.getData(type);
|
}
|
|
@Override
|
@GetMapping(PREDICT_HST_DATA)
|
public void hstPredictData(String type) {
|
hstPredictService.predictData(type);
|
}
|
|
@Override
|
@GetMapping(GET_BATCH_DATA)
|
public void batchData(String type) {
|
alarmGetService.batchData(type);
|
}
|
|
@Override
|
@GetMapping(ALARM_GET_DATA)
|
public void alarmGetData(String type) {
|
alarmGetService.alarmGetData(type);
|
}
|
|
@Override
|
@PostMapping(GET_ALARM_DETAIL)
|
public List<AlarmGetVO> getAlarmDetail(AlarmGetVO alarmGet) {
|
return alarmGetService.getAlarmDetail(alarmGet);
|
}
|
}
|