DataInHarmV该名称

This commit is contained in:
guofeihu
2024-09-14 09:21:32 +08:00
parent 0ca611213f
commit ac08343f56
4 changed files with 42 additions and 42 deletions

View File

@@ -1,13 +0,0 @@
package com.njcn.influx.service;
import com.njcn.influx.pojo.po.DataInHarmRateV;
import java.util.List;
/**
* @author guofeihu
* @version 1.0.0
* @date 2024年09月13日 11:01
*/
public interface DataInHarmRateVService {
List<DataInHarmRateV> getNewDataInHarmRateV(String lineIndex, String startTime, String endTime);
}

View File

@@ -0,0 +1,13 @@
package com.njcn.influx.service;
import com.njcn.influx.pojo.po.DataInHarmV;
import java.util.List;
/**
* @author guofeihu
* @version 1.0.0
* @date 2024年09月13日 11:01
*/
public interface DataInHarmVService {
List<DataInHarmV> getNewDataInHarmV(String lineIndex, String startTime, String endTime);
}

View File

@@ -1,29 +0,0 @@
package com.njcn.influx.service.impl;
import com.njcn.influx.imapper.DataInHarmRateVMapper;
import com.njcn.influx.pojo.po.DataInHarmRateV;
import com.njcn.influx.query.InfluxQueryWrapper;
import com.njcn.influx.service.DataInHarmRateVService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* @author guofeihu
* @version 1.0.0
* @date 2024年09月13日 11:01
*/
@Service
@RequiredArgsConstructor
public class DataInHarmRateVServiceImpl implements DataInHarmRateVService {
private final DataInHarmRateVMapper dataInHarmRateVMapper;
@Override
public List<DataInHarmRateV> getNewDataInHarmRateV(String lineIndex, String startTime, String endTime) {
InfluxQueryWrapper influxQueryWrapper = new InfluxQueryWrapper(DataInHarmRateV.class);
influxQueryWrapper.eq(DataInHarmRateV::getLineId, lineIndex)
.between(DataInHarmRateV::getTime, startTime, endTime);;
return dataInHarmRateVMapper.getStatisticsByWraper(influxQueryWrapper);
}
}

View File

@@ -0,0 +1,29 @@
package com.njcn.influx.service.impl;
import com.njcn.influx.imapper.DataInHarmVMapper;
import com.njcn.influx.pojo.po.DataInHarmV;
import com.njcn.influx.query.InfluxQueryWrapper;
import com.njcn.influx.service.DataInHarmVService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* @author guofeihu
* @version 1.0.0
* @date 2024年09月13日 11:01
*/
@Service
@RequiredArgsConstructor
public class DataInHarmVServiceImpl implements DataInHarmVService {
private final DataInHarmVMapper dataInHarmVMapper;
@Override
public List<DataInHarmV> getNewDataInHarmV(String lineIndex, String startTime, String endTime) {
InfluxQueryWrapper influxQueryWrapper = new InfluxQueryWrapper(DataInHarmV.class);
influxQueryWrapper.eq(DataInHarmV::getLineId, lineIndex)
.between(DataInHarmV::getTime, startTime, endTime);;
return dataInHarmVMapper.getStatisticsByWraper(influxQueryWrapper);
}
}