package com.dy.pipIrrWechat.mqtt;
|
|
import com.dy.pipIrrGlobal.daoPr.PrStManureMapper;
|
import com.dy.pipIrrGlobal.daoPr.PrStSoilMapper;
|
import com.dy.pipIrrGlobal.daoPr.PrStWeatherMapper;
|
import com.dy.pipIrrGlobal.voPr.VoManure;
|
import com.dy.pipIrrGlobal.voPr.VoMqttSimple;
|
import com.dy.pipIrrGlobal.voPr.VoSoil;
|
import com.dy.pipIrrGlobal.voPr.VoWeather;
|
import lombok.extern.slf4j.Slf4j;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Service;
|
|
import java.util.List;
|
|
/**
|
* @Author: liurunyu
|
* @Date: 2025/8/13 16:41
|
* @Description
|
*/
|
@Slf4j
|
@Service
|
public class MqttSv {
|
|
@Autowired
|
private PrStManureMapper manureDao;
|
@Autowired
|
private PrStSoilMapper soilDao;
|
@Autowired
|
private PrStWeatherMapper weatherDao;
|
|
public List<VoMqttSimple> allManureSimple(){
|
return this.manureDao.selectAllSimple() ;
|
}
|
|
public List<VoMqttSimple> allSoilSimple(){
|
return this.soilDao.selectAllSimple() ;
|
}
|
|
public List<VoMqttSimple> allWeatherSimple(){
|
return this.weatherDao.selectAllSimple() ;
|
}
|
|
public String oneManureFBoxId(Long id){
|
VoManure vo = manureDao.selectOne(id);
|
if(vo != null){
|
return vo.fboxId ;
|
}
|
return null ;
|
}
|
public String oneSoilFBoxId(Long id){
|
VoSoil vo = soilDao.selectOne(id);
|
if(vo != null){
|
return vo.fboxId ;
|
}
|
return null ;
|
}
|
public String oneWeatherFBoxId(Long id){
|
VoWeather vo = weatherDao.selectOne(id);
|
if(vo != null){
|
return vo.fboxId ;
|
}
|
return null ;
|
}
|
|
}
|