新增一些公共查询方法
This commit is contained in:
@@ -2,11 +2,14 @@ package com.njcn.influx.service.impl;
|
||||
|
||||
import com.njcn.influx.imapper.DataHarmRateVMapper;
|
||||
import com.njcn.influx.pojo.po.DataHarmRateV;
|
||||
import com.njcn.influx.pojo.po.DataV;
|
||||
import com.njcn.influx.query.InfluxQueryWrapper;
|
||||
import com.njcn.influx.service.DataHarmRateVService;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author hongawen
|
||||
* @version 1.0.0
|
||||
@@ -23,4 +26,12 @@ public class DataHarmRateVServiceImpl implements DataHarmRateVService {
|
||||
public DataHarmRateV getMeanAllTimesData(InfluxQueryWrapper influxQueryWrapper) {
|
||||
return dataHarmRateVMapper.getMeanAllTimesData(influxQueryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DataHarmRateV> getNewDataHarmRateV(String lineIndex, String startTime, String endTime) {
|
||||
InfluxQueryWrapper influxQueryWrapper = new InfluxQueryWrapper(DataHarmRateV.class);
|
||||
influxQueryWrapper.eq(DataHarmRateV::getLineId, lineIndex)
|
||||
.between(DataHarmRateV::getTime, startTime, endTime);;
|
||||
return dataHarmRateVMapper.getStatisticsByWraper(influxQueryWrapper);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user