PCS+BMS总览+BMS电池簇-框架

This commit is contained in:
2025-06-24 01:18:07 +08:00
parent a2d8b6876d
commit 7134bc03f8
16 changed files with 1582 additions and 8 deletions

View File

@ -44,4 +44,31 @@ public class EmsSiteMonitorController extends BaseController{
{
return success(iSingleSiteService.getRunningGraph(siteId));
}
/**
* 单站监控-设备监控-PCS
*/
@GetMapping("/getPcsDetailInfo")
public AjaxResult getPcsDetailInfo(@RequestParam Long siteId)
{
return success(iSingleSiteService.getPcsDetailInfo(siteId));
}
/**
* 单站监控-设备监控-BMS总览
*/
@GetMapping("/getBMSOverView")
public AjaxResult getBMSOverView(@RequestParam Long siteId)
{
return success(iSingleSiteService.getBMSOverView(siteId));
}
/**
* 单站监控-设备监控-BMS电池簇
*/
@GetMapping("/getBMSBatteryCluster")
public AjaxResult getBMSBatteryCluster(@RequestParam Long siteId)
{
return success(iSingleSiteService.getBMSBatteryCluster(siteId));
}
}

View File

@ -0,0 +1,269 @@
package com.xzzn.ems.domain;
import java.math.BigDecimal;
import com.xzzn.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.xzzn.common.annotation.Excel;
/**
* 电池簇数据对象 ems_battery_cluster
*
* @author xzzn
* @date 2025-06-22
*/
public class EmsBatteryCluster extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** */
private Long id;
/** 工作状态 */
@Excel(name = "工作状态")
private String workStatus;
/** 与PCS通信状态 */
@Excel(name = "与PCS通信状态")
private String pcsCommunicationStatus;
/** 与EMS通信状态 */
@Excel(name = "与EMS通信状态")
private String emsCommunicationStatus;
/** 簇电压 (V) */
@Excel(name = "簇电压 (V)")
private BigDecimal clusterVoltage;
/** 可充电量 (kWh) */
@Excel(name = "可充电量 (kWh)")
private BigDecimal chargeableCapacity;
/** 累计充电量 (kWh) */
@Excel(name = "累计充电量 (kWh)")
private BigDecimal totalChargedCapacity;
/** 簇电流 (A) */
@Excel(name = "簇电流 (A)")
private BigDecimal clusterCurrent;
/** 可放电量 (kWh) */
@Excel(name = "可放电量 (kWh)")
private BigDecimal dischargeableCapacity;
/** 累计放电量 (kWh) */
@Excel(name = "累计放电量 (kWh)")
private BigDecimal totalDischargedCapacity;
/** SOH (%) */
@Excel(name = "SOH (%)")
private BigDecimal soh;
/** 平均温度 (℃) */
@Excel(name = "平均温度 (℃)")
private BigDecimal averageTemperature;
/** 绝缘电阻 (Ω) */
@Excel(name = "绝缘电阻 (Ω)")
private BigDecimal insulationResistance;
/** 当前SOC (%) */
@Excel(name = "当前SOC (%)")
private BigDecimal currentSoc;
/** 站点id */
@Excel(name = "站点id")
private Long siteId;
/** 设备唯一标识符 */
@Excel(name = "设备唯一标识符")
private Long deviceId;
public void setId(Long id)
{
this.id = id;
}
public Long getId()
{
return id;
}
public void setWorkStatus(String workStatus)
{
this.workStatus = workStatus;
}
public String getWorkStatus()
{
return workStatus;
}
public void setPcsCommunicationStatus(String pcsCommunicationStatus)
{
this.pcsCommunicationStatus = pcsCommunicationStatus;
}
public String getPcsCommunicationStatus()
{
return pcsCommunicationStatus;
}
public void setEmsCommunicationStatus(String emsCommunicationStatus)
{
this.emsCommunicationStatus = emsCommunicationStatus;
}
public String getEmsCommunicationStatus()
{
return emsCommunicationStatus;
}
public void setClusterVoltage(BigDecimal clusterVoltage)
{
this.clusterVoltage = clusterVoltage;
}
public BigDecimal getClusterVoltage()
{
return clusterVoltage;
}
public void setChargeableCapacity(BigDecimal chargeableCapacity)
{
this.chargeableCapacity = chargeableCapacity;
}
public BigDecimal getChargeableCapacity()
{
return chargeableCapacity;
}
public void setTotalChargedCapacity(BigDecimal totalChargedCapacity)
{
this.totalChargedCapacity = totalChargedCapacity;
}
public BigDecimal getTotalChargedCapacity()
{
return totalChargedCapacity;
}
public void setClusterCurrent(BigDecimal clusterCurrent)
{
this.clusterCurrent = clusterCurrent;
}
public BigDecimal getClusterCurrent()
{
return clusterCurrent;
}
public void setDischargeableCapacity(BigDecimal dischargeableCapacity)
{
this.dischargeableCapacity = dischargeableCapacity;
}
public BigDecimal getDischargeableCapacity()
{
return dischargeableCapacity;
}
public void setTotalDischargedCapacity(BigDecimal totalDischargedCapacity)
{
this.totalDischargedCapacity = totalDischargedCapacity;
}
public BigDecimal getTotalDischargedCapacity()
{
return totalDischargedCapacity;
}
public void setSoh(BigDecimal soh)
{
this.soh = soh;
}
public BigDecimal getSoh()
{
return soh;
}
public void setAverageTemperature(BigDecimal averageTemperature)
{
this.averageTemperature = averageTemperature;
}
public BigDecimal getAverageTemperature()
{
return averageTemperature;
}
public void setInsulationResistance(BigDecimal insulationResistance)
{
this.insulationResistance = insulationResistance;
}
public BigDecimal getInsulationResistance()
{
return insulationResistance;
}
public void setCurrentSoc(BigDecimal currentSoc)
{
this.currentSoc = currentSoc;
}
public BigDecimal getCurrentSoc()
{
return currentSoc;
}
public void setSiteId(Long siteId)
{
this.siteId = siteId;
}
public Long getSiteId()
{
return siteId;
}
public void setDeviceId(Long deviceId)
{
this.deviceId = deviceId;
}
public Long getDeviceId()
{
return deviceId;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("workStatus", getWorkStatus())
.append("pcsCommunicationStatus", getPcsCommunicationStatus())
.append("emsCommunicationStatus", getEmsCommunicationStatus())
.append("clusterVoltage", getClusterVoltage())
.append("chargeableCapacity", getChargeableCapacity())
.append("totalChargedCapacity", getTotalChargedCapacity())
.append("clusterCurrent", getClusterCurrent())
.append("dischargeableCapacity", getDischargeableCapacity())
.append("totalDischargedCapacity", getTotalDischargedCapacity())
.append("soh", getSoh())
.append("averageTemperature", getAverageTemperature())
.append("insulationResistance", getInsulationResistance())
.append("currentSoc", getCurrentSoc())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.append("remark", getRemark())
.append("siteId", getSiteId())
.append("deviceId", getDeviceId())
.toString();
}
}

View File

@ -0,0 +1,269 @@
package com.xzzn.ems.domain;
import java.math.BigDecimal;
import com.xzzn.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.xzzn.common.annotation.Excel;
/**
* 电池堆数据对象 ems_battery_stack
*
* @author xzzn
* @date 2025-06-22
*/
public class EmsBatteryStack extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** */
private Long id;
/** 工作状态 */
@Excel(name = "工作状态")
private String workStatus;
/** 与PCS通信状态 */
@Excel(name = "与PCS通信状态")
private String pcsCommunicationStatus;
/** 与EMS通信状态 */
@Excel(name = "与EMS通信状态")
private String emsCommunicationStatus;
/** 电池堆总电压 (V) */
@Excel(name = "电池堆总电压 (V)")
private BigDecimal totalVoltage;
/** 可充电量 (kWh) */
@Excel(name = "可充电量 (kWh)")
private BigDecimal chargeableCapacity;
/** 累计充电量 (kWh) */
@Excel(name = "累计充电量 (kWh)")
private BigDecimal totalChargedCapacity;
/** 电池堆总电流 (A) */
@Excel(name = "电池堆总电流 (A)")
private BigDecimal totalCurrent;
/** 可放电量 (kWh) */
@Excel(name = "可放电量 (kWh)")
private BigDecimal dischargeableCapacity;
/** 累计放电量 (kWh) */
@Excel(name = "累计放电量 (kWh)")
private BigDecimal totalDischargedCapacity;
/** SOH (%) */
@Excel(name = "SOH (%)")
private BigDecimal soh;
/** 平均温度 (℃) */
@Excel(name = "平均温度 (℃)")
private BigDecimal averageTemperature;
/** 绝缘电阻 (Ω) */
@Excel(name = "绝缘电阻 (Ω)")
private BigDecimal insulationResistance;
/** 当前SOC (%) */
@Excel(name = "当前SOC (%)")
private BigDecimal currentSoc;
/** 站点id */
@Excel(name = "站点id")
private Long siteId;
/** 设备唯一标识符 */
@Excel(name = "设备唯一标识符")
private Long deviceId;
public void setId(Long id)
{
this.id = id;
}
public Long getId()
{
return id;
}
public void setWorkStatus(String workStatus)
{
this.workStatus = workStatus;
}
public String getWorkStatus()
{
return workStatus;
}
public void setPcsCommunicationStatus(String pcsCommunicationStatus)
{
this.pcsCommunicationStatus = pcsCommunicationStatus;
}
public String getPcsCommunicationStatus()
{
return pcsCommunicationStatus;
}
public void setEmsCommunicationStatus(String emsCommunicationStatus)
{
this.emsCommunicationStatus = emsCommunicationStatus;
}
public String getEmsCommunicationStatus()
{
return emsCommunicationStatus;
}
public void setTotalVoltage(BigDecimal totalVoltage)
{
this.totalVoltage = totalVoltage;
}
public BigDecimal getTotalVoltage()
{
return totalVoltage;
}
public void setChargeableCapacity(BigDecimal chargeableCapacity)
{
this.chargeableCapacity = chargeableCapacity;
}
public BigDecimal getChargeableCapacity()
{
return chargeableCapacity;
}
public void setTotalChargedCapacity(BigDecimal totalChargedCapacity)
{
this.totalChargedCapacity = totalChargedCapacity;
}
public BigDecimal getTotalChargedCapacity()
{
return totalChargedCapacity;
}
public void setTotalCurrent(BigDecimal totalCurrent)
{
this.totalCurrent = totalCurrent;
}
public BigDecimal getTotalCurrent()
{
return totalCurrent;
}
public void setDischargeableCapacity(BigDecimal dischargeableCapacity)
{
this.dischargeableCapacity = dischargeableCapacity;
}
public BigDecimal getDischargeableCapacity()
{
return dischargeableCapacity;
}
public void setTotalDischargedCapacity(BigDecimal totalDischargedCapacity)
{
this.totalDischargedCapacity = totalDischargedCapacity;
}
public BigDecimal getTotalDischargedCapacity()
{
return totalDischargedCapacity;
}
public void setSoh(BigDecimal soh)
{
this.soh = soh;
}
public BigDecimal getSoh()
{
return soh;
}
public void setAverageTemperature(BigDecimal averageTemperature)
{
this.averageTemperature = averageTemperature;
}
public BigDecimal getAverageTemperature()
{
return averageTemperature;
}
public void setInsulationResistance(BigDecimal insulationResistance)
{
this.insulationResistance = insulationResistance;
}
public BigDecimal getInsulationResistance()
{
return insulationResistance;
}
public void setCurrentSoc(BigDecimal currentSoc)
{
this.currentSoc = currentSoc;
}
public BigDecimal getCurrentSoc()
{
return currentSoc;
}
public void setSiteId(Long siteId)
{
this.siteId = siteId;
}
public Long getSiteId()
{
return siteId;
}
public void setDeviceId(Long deviceId)
{
this.deviceId = deviceId;
}
public Long getDeviceId()
{
return deviceId;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("workStatus", getWorkStatus())
.append("pcsCommunicationStatus", getPcsCommunicationStatus())
.append("emsCommunicationStatus", getEmsCommunicationStatus())
.append("totalVoltage", getTotalVoltage())
.append("chargeableCapacity", getChargeableCapacity())
.append("totalChargedCapacity", getTotalChargedCapacity())
.append("totalCurrent", getTotalCurrent())
.append("dischargeableCapacity", getDischargeableCapacity())
.append("totalDischargedCapacity", getTotalDischargedCapacity())
.append("soh", getSoh())
.append("averageTemperature", getAverageTemperature())
.append("insulationResistance", getInsulationResistance())
.append("currentSoc", getCurrentSoc())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.append("remark", getRemark())
.append("siteId", getSiteId())
.append("deviceId", getDeviceId())
.toString();
}
}

View File

@ -22,7 +22,7 @@ public class EmsPcsData extends BaseEntity
private Long id;
/** 数据更新时间 */
@JsonFormat(pattern = "yyyy-MM-dd")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "数据更新时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date dataUpdateTime;

View File

@ -0,0 +1,76 @@
package com.xzzn.ems.domain.vo;
import java.math.BigDecimal;
/**
* BMS电池簇-电池单体数据
*/
public class BMSBatteryClusterDataList {
/**
* 名称
*/
private String dataName;
/** 单体平均值 */
private BigDecimal avgData;
/** 单体最小值 */
private BigDecimal minData;
/** 单体最小值ID */
private BigDecimal minDataID;
/** 单体最大值 */
private BigDecimal maxData;
/** 单体最大值ID */
private BigDecimal maxDataID;
public String getDataName() {
return dataName;
}
public void setDataName(String dataName) {
this.dataName = dataName;
}
public BigDecimal getAvgData() {
return avgData;
}
public void setAvgData(BigDecimal avgData) {
this.avgData = avgData;
}
public BigDecimal getMinData() {
return minData;
}
public void setMinData(BigDecimal minData) {
this.minData = minData;
}
public BigDecimal getMinDataID() {
return minDataID;
}
public void setMinDataID(BigDecimal minDataID) {
this.minDataID = minDataID;
}
public BigDecimal getMaxData() {
return maxData;
}
public void setMaxData(BigDecimal maxData) {
this.maxData = maxData;
}
public BigDecimal getMaxDataID() {
return maxDataID;
}
public void setMaxDataID(BigDecimal maxDataID) {
this.maxDataID = maxDataID;
}
}

View File

@ -0,0 +1,175 @@
package com.xzzn.ems.domain.vo;
import java.math.BigDecimal;
import java.util.List;
/**
* BMS电池簇数据
*
*/
public class BMSBatteryClusterVo {
private Long id;
/** 工作状态 */
private String workStatus;
/** 与PCS通信状态 */
private String pcsCommunicationStatus;
/** 与EMS通信状态 */
private String emsCommunicationStatus;
/** 簇电压 (V) */
private BigDecimal clusterVoltage;
/** 可充电量 (kWh) */
private BigDecimal chargeableCapacity;
/** 累计充电量 (kWh) */
private BigDecimal totalChargedCapacity;
/** 簇电流 (A) */
private BigDecimal clusterCurrent;
/** 可放电量 (kWh) */
private BigDecimal dischargeableCapacity;
/** 累计放电量 (kWh) */
private BigDecimal totalDischargedCapacity;
/** SOH (%) */
private BigDecimal soh;
/** 平均温度 (℃) */
private BigDecimal averageTemperature;
/** 绝缘电阻 (Ω) */
private BigDecimal insulationResistance;
/** 当前SOC (%) */
private BigDecimal currentSoc;
private List<BMSBatteryClusterDataList> batteryDataList;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getWorkStatus() {
return workStatus;
}
public void setWorkStatus(String workStatus) {
this.workStatus = workStatus;
}
public String getPcsCommunicationStatus() {
return pcsCommunicationStatus;
}
public void setPcsCommunicationStatus(String pcsCommunicationStatus) {
this.pcsCommunicationStatus = pcsCommunicationStatus;
}
public String getEmsCommunicationStatus() {
return emsCommunicationStatus;
}
public void setEmsCommunicationStatus(String emsCommunicationStatus) {
this.emsCommunicationStatus = emsCommunicationStatus;
}
public BigDecimal getClusterVoltage() {
return clusterVoltage;
}
public void setClusterVoltage(BigDecimal clusterVoltage) {
this.clusterVoltage = clusterVoltage;
}
public BigDecimal getChargeableCapacity() {
return chargeableCapacity;
}
public void setChargeableCapacity(BigDecimal chargeableCapacity) {
this.chargeableCapacity = chargeableCapacity;
}
public BigDecimal getTotalChargedCapacity() {
return totalChargedCapacity;
}
public void setTotalChargedCapacity(BigDecimal totalChargedCapacity) {
this.totalChargedCapacity = totalChargedCapacity;
}
public BigDecimal getClusterCurrent() {
return clusterCurrent;
}
public void setClusterCurrent(BigDecimal clusterCurrent) {
this.clusterCurrent = clusterCurrent;
}
public BigDecimal getDischargeableCapacity() {
return dischargeableCapacity;
}
public void setDischargeableCapacity(BigDecimal dischargeableCapacity) {
this.dischargeableCapacity = dischargeableCapacity;
}
public BigDecimal getTotalDischargedCapacity() {
return totalDischargedCapacity;
}
public void setTotalDischargedCapacity(BigDecimal totalDischargedCapacity) {
this.totalDischargedCapacity = totalDischargedCapacity;
}
public BigDecimal getSoh() {
return soh;
}
public void setSoh(BigDecimal soh) {
this.soh = soh;
}
public BigDecimal getAverageTemperature() {
return averageTemperature;
}
public void setAverageTemperature(BigDecimal averageTemperature) {
this.averageTemperature = averageTemperature;
}
public BigDecimal getInsulationResistance() {
return insulationResistance;
}
public void setInsulationResistance(BigDecimal insulationResistance) {
this.insulationResistance = insulationResistance;
}
public BigDecimal getCurrentSoc() {
return currentSoc;
}
public void setCurrentSoc(BigDecimal currentSoc) {
this.currentSoc = currentSoc;
}
public List<BMSBatteryClusterDataList> getBatteryDataList() {
return batteryDataList;
}
public void setBatteryDataList(List<BMSBatteryClusterDataList> batteryDataList) {
this.batteryDataList = batteryDataList;
}
}

View File

@ -0,0 +1,98 @@
package com.xzzn.ems.domain.vo;
import java.math.BigDecimal;
/**
* BMS总览-电池堆电池簇单体数据
*/
public class BMSBatteryDataList {
/**
* 簇号
*/
private Long clusterId;
/** 簇电压 (V) */
private BigDecimal clusterVoltage;
/** 簇电流 (A) */
private BigDecimal clusterCurrent;
/** 簇SOC (%) */
private BigDecimal currentSoc;
/** 单体最高电压 (V) */
private BigDecimal maxVoltage;
/** 单体最低电压 (V) */
private BigDecimal minVoltage;
/** 单体最高温度 (℃) */
private BigDecimal maxTemperature;
/** 单体最低温度 (℃) */
private BigDecimal minTemperature;
public Long getClusterId() {
return clusterId;
}
public void setClusterId(Long clusterId) {
this.clusterId = clusterId;
}
public BigDecimal getMinTemperature() {
return minTemperature;
}
public void setMinTemperature(BigDecimal minTemperature) {
this.minTemperature = minTemperature;
}
public BigDecimal getMaxTemperature() {
return maxTemperature;
}
public void setMaxTemperature(BigDecimal maxTemperature) {
this.maxTemperature = maxTemperature;
}
public BigDecimal getMinVoltage() {
return minVoltage;
}
public void setMinVoltage(BigDecimal minVoltage) {
this.minVoltage = minVoltage;
}
public BigDecimal getMaxVoltage() {
return maxVoltage;
}
public void setMaxVoltage(BigDecimal maxVoltage) {
this.maxVoltage = maxVoltage;
}
public BigDecimal getCurrentSoc() {
return currentSoc;
}
public void setCurrentSoc(BigDecimal currentSoc) {
this.currentSoc = currentSoc;
}
public BigDecimal getClusterCurrent() {
return clusterCurrent;
}
public void setClusterCurrent(BigDecimal clusterCurrent) {
this.clusterCurrent = clusterCurrent;
}
public BigDecimal getClusterVoltage() {
return clusterVoltage;
}
public void setClusterVoltage(BigDecimal clusterVoltage) {
this.clusterVoltage = clusterVoltage;
}
}

View File

@ -0,0 +1,175 @@
package com.xzzn.ems.domain.vo;
import java.math.BigDecimal;
import java.util.List;
/**
* BMS总览数据
*
*/
public class BMSOverViewVo {
private Long id;
/** 工作状态 */
private String workStatus;
/** 与PCS通信状态 */
private String pcsCommunicationStatus;
/** 与EMS通信状态 */
private String emsCommunicationStatus;
/** 电池堆总电压 (V) */
private BigDecimal totalVoltage;
/** 可充电量 (kWh) */
private BigDecimal chargeableCapacity;
/** 累计充电量 (kWh) */
private BigDecimal totalChargedCapacity;
/** 电池堆总电流 (A) */
private BigDecimal totalCurrent;
/** 可放电量 (kWh) */
private BigDecimal dischargeableCapacity;
/** 累计放电量 (kWh) */
private BigDecimal totalDischargedCapacity;
/** SOH (%) */
private BigDecimal soh;
/** 平均温度 (℃) */
private BigDecimal averageTemperature;
/** 绝缘电阻 (Ω) */
private BigDecimal insulationResistance;
/** 当前SOC (%) */
private BigDecimal currentSoc;
private List<BMSBatteryDataList> batteryDataList;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getWorkStatus() {
return workStatus;
}
public void setWorkStatus(String workStatus) {
this.workStatus = workStatus;
}
public String getPcsCommunicationStatus() {
return pcsCommunicationStatus;
}
public void setPcsCommunicationStatus(String pcsCommunicationStatus) {
this.pcsCommunicationStatus = pcsCommunicationStatus;
}
public String getEmsCommunicationStatus() {
return emsCommunicationStatus;
}
public void setEmsCommunicationStatus(String emsCommunicationStatus) {
this.emsCommunicationStatus = emsCommunicationStatus;
}
public BigDecimal getTotalVoltage() {
return totalVoltage;
}
public void setTotalVoltage(BigDecimal totalVoltage) {
this.totalVoltage = totalVoltage;
}
public BigDecimal getChargeableCapacity() {
return chargeableCapacity;
}
public void setChargeableCapacity(BigDecimal chargeableCapacity) {
this.chargeableCapacity = chargeableCapacity;
}
public BigDecimal getTotalChargedCapacity() {
return totalChargedCapacity;
}
public void setTotalChargedCapacity(BigDecimal totalChargedCapacity) {
this.totalChargedCapacity = totalChargedCapacity;
}
public BigDecimal getTotalCurrent() {
return totalCurrent;
}
public void setTotalCurrent(BigDecimal totalCurrent) {
this.totalCurrent = totalCurrent;
}
public BigDecimal getDischargeableCapacity() {
return dischargeableCapacity;
}
public void setDischargeableCapacity(BigDecimal dischargeableCapacity) {
this.dischargeableCapacity = dischargeableCapacity;
}
public BigDecimal getTotalDischargedCapacity() {
return totalDischargedCapacity;
}
public void setTotalDischargedCapacity(BigDecimal totalDischargedCapacity) {
this.totalDischargedCapacity = totalDischargedCapacity;
}
public BigDecimal getSoh() {
return soh;
}
public void setSoh(BigDecimal soh) {
this.soh = soh;
}
public BigDecimal getAverageTemperature() {
return averageTemperature;
}
public void setAverageTemperature(BigDecimal averageTemperature) {
this.averageTemperature = averageTemperature;
}
public BigDecimal getInsulationResistance() {
return insulationResistance;
}
public void setInsulationResistance(BigDecimal insulationResistance) {
this.insulationResistance = insulationResistance;
}
public BigDecimal getCurrentSoc() {
return currentSoc;
}
public void setCurrentSoc(BigDecimal currentSoc) {
this.currentSoc = currentSoc;
}
public List<BMSBatteryDataList> getBatteryDataList() {
return batteryDataList;
}
public void setBatteryDataList(List<BMSBatteryDataList> batteryDataList) {
this.batteryDataList = batteryDataList;
}
}

View File

@ -0,0 +1,68 @@
package com.xzzn.ems.mapper;
import java.util.List;
import com.xzzn.ems.domain.EmsBatteryCluster;
/**
* 电池簇数据Mapper接口
*
* @author xzzn
* @date 2025-06-22
*/
public interface EmsBatteryClusterMapper
{
/**
* 查询电池簇数据
*
* @param id 电池簇数据主键
* @return 电池簇数据
*/
public EmsBatteryCluster selectEmsBatteryClusterById(Long id);
/**
* 查询电池簇数据列表
*
* @param emsBatteryCluster 电池簇数据
* @return 电池簇数据集合
*/
public List<EmsBatteryCluster> selectEmsBatteryClusterList(EmsBatteryCluster emsBatteryCluster);
/**
* 新增电池簇数据
*
* @param emsBatteryCluster 电池簇数据
* @return 结果
*/
public int insertEmsBatteryCluster(EmsBatteryCluster emsBatteryCluster);
/**
* 修改电池簇数据
*
* @param emsBatteryCluster 电池簇数据
* @return 结果
*/
public int updateEmsBatteryCluster(EmsBatteryCluster emsBatteryCluster);
/**
* 删除电池簇数据
*
* @param id 电池簇数据主键
* @return 结果
*/
public int deleteEmsBatteryClusterById(Long id);
/**
* 批量删除电池簇数据
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public int deleteEmsBatteryClusterByIds(Long[] ids);
/**
* 根据site_id获取电池簇数据
* @param siteId
* @return
*/
public EmsBatteryCluster getBMSBatteryCluster(Long siteId);
}

View File

@ -0,0 +1,68 @@
package com.xzzn.ems.mapper;
import java.util.List;
import com.xzzn.ems.domain.EmsBatteryStack;
/**
* 电池堆数据Mapper接口
*
* @author xzzn
* @date 2025-06-23
*/
public interface EmsBatteryStackMapper
{
/**
* 查询电池堆数据
*
* @param id 电池堆数据主键
* @return 电池堆数据
*/
public EmsBatteryStack selectEmsBatteryStackById(Long id);
/**
* 查询电池堆数据列表
*
* @param emsBatteryStack 电池堆数据
* @return 电池堆数据集合
*/
public List<EmsBatteryStack> selectEmsBatteryStackList(EmsBatteryStack emsBatteryStack);
/**
* 新增电池堆数据
*
* @param emsBatteryStack 电池堆数据
* @return 结果
*/
public int insertEmsBatteryStack(EmsBatteryStack emsBatteryStack);
/**
* 修改电池堆数据
*
* @param emsBatteryStack 电池堆数据
* @return 结果
*/
public int updateEmsBatteryStack(EmsBatteryStack emsBatteryStack);
/**
* 删除电池堆数据
*
* @param id 电池堆数据主键
* @return 结果
*/
public int deleteEmsBatteryStackById(Long id);
/**
* 批量删除电池堆数据
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public int deleteEmsBatteryStackByIds(Long[] ids);
/**
* 获取电池堆信息
* @param siteId
* @return
*/
public EmsBatteryStack selectEmsBatteryStackBySiteId(Long siteId);
}

View File

@ -90,4 +90,11 @@ public interface EmsPcsDataMapper
* @return
*/
public List<ElectricIndexList> getElectDataList();
/**
* 根据site_id获取pcs最新update的数据
* @param siteId
* @return
*/
public EmsPcsData getPcsDetailInfoBySiteId(Long siteId);
}

View File

@ -1,8 +1,7 @@
package com.xzzn.ems.service;
import com.xzzn.ems.domain.vo.SiteMonitorHomeVo;
import com.xzzn.ems.domain.vo.SiteMonitorRuningHeadInfoVo;
import com.xzzn.ems.domain.vo.SiteMonitorRuningInfoVo;
import com.xzzn.ems.domain.EmsPcsData;
import com.xzzn.ems.domain.vo.*;
/**
* 单点监控 服务层
@ -17,4 +16,10 @@ public interface ISingleSiteService
public SiteMonitorRuningHeadInfoVo getSiteRunningHeadInfo(Long siteId);
public SiteMonitorRuningInfoVo getRunningGraph(Long siteId);
public EmsPcsData getPcsDetailInfo(Long siteId);
public BMSOverViewVo getBMSOverView(Long siteId);
public BMSBatteryClusterVo getBMSBatteryCluster(Long siteId);
}

View File

@ -1,11 +1,13 @@
package com.xzzn.ems.service.impl;
import com.xzzn.common.utils.StringUtils;
import com.xzzn.common.utils.bean.BeanUtils;
import com.xzzn.ems.domain.EmsBatteryCluster;
import com.xzzn.ems.domain.EmsBatteryData;
import com.xzzn.ems.domain.EmsBatteryStack;
import com.xzzn.ems.domain.EmsPcsData;
import com.xzzn.ems.domain.vo.*;
import com.xzzn.ems.mapper.EmsAlarmRecordsMapper;
import com.xzzn.ems.mapper.EmsBatteryDataMapper;
import com.xzzn.ems.mapper.EmsPcsDataMapper;
import com.xzzn.ems.mapper.*;
import com.xzzn.ems.service.ISingleSiteService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@ -26,6 +28,10 @@ public class SingleSiteServiceImpl implements ISingleSiteService {
private EmsAlarmRecordsMapper emsAlarmRecordsMapper;
@Autowired
private EmsBatteryDataMapper emsBatteryDataMapper;
@Autowired
private EmsBatteryStackMapper emsBatteryStackMapper;
@Autowired
private EmsBatteryClusterMapper emsBatteryClusterMapper;
@Override
public SiteMonitorHomeVo getSiteMonitorDataVo(Long siteId) {
@ -115,9 +121,32 @@ public class SingleSiteServiceImpl implements ISingleSiteService {
//pcs平均温度list
//电池平均soclist
//电池平均温度list
}
return siteMonitorRuningInfoVo;
}
// 根据site_id获取pcs详细数据
@Override
public EmsPcsData getPcsDetailInfo(Long siteId) {
return emsPcsDataMapper.getPcsDetailInfoBySiteId(siteId);
}
// 获取BMS总览数据
@Override
public BMSOverViewVo getBMSOverView(Long siteId) {
BMSOverViewVo bmsOverViewVo = new BMSOverViewVo();
EmsBatteryStack emsBatteryStack = emsBatteryStackMapper.selectEmsBatteryStackBySiteId(siteId);
BeanUtils.copyProperties(emsBatteryStack, bmsOverViewVo);
return bmsOverViewVo;
}
// 获取BMS电池簇数据
@Override
public BMSBatteryClusterVo getBMSBatteryCluster(Long siteId) {
BMSBatteryClusterVo bmsBatteryClusterVo = new BMSBatteryClusterVo();
EmsBatteryCluster emsBatteryCluster = emsBatteryClusterMapper.getBMSBatteryCluster(siteId);
BeanUtils.copyProperties(emsBatteryCluster, bmsBatteryClusterVo);
return bmsBatteryClusterVo;
}
}

View File

@ -0,0 +1,151 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xzzn.ems.mapper.EmsBatteryClusterMapper">
<resultMap type="EmsBatteryCluster" id="EmsBatteryClusterResult">
<result property="id" column="id" />
<result property="workStatus" column="work_status" />
<result property="pcsCommunicationStatus" column="pcs_communication_status" />
<result property="emsCommunicationStatus" column="ems_communication_status" />
<result property="clusterVoltage" column="cluster_voltage" />
<result property="chargeableCapacity" column="chargeable_capacity" />
<result property="totalChargedCapacity" column="total_charged_capacity" />
<result property="clusterCurrent" column="cluster_current" />
<result property="dischargeableCapacity" column="dischargeable_capacity" />
<result property="totalDischargedCapacity" column="total_discharged_capacity" />
<result property="soh" column="soh" />
<result property="averageTemperature" column="average_temperature" />
<result property="insulationResistance" column="insulation_resistance" />
<result property="currentSoc" column="current_soc" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="remark" column="remark" />
<result property="siteId" column="site_id" />
<result property="deviceId" column="device_id" />
</resultMap>
<sql id="selectEmsBatteryClusterVo">
select id, work_status, pcs_communication_status, ems_communication_status, cluster_voltage, chargeable_capacity, total_charged_capacity, cluster_current, dischargeable_capacity, total_discharged_capacity, soh, average_temperature, insulation_resistance, current_soc, create_by, create_time, update_by, update_time, remark, site_id, device_id from ems_battery_cluster
</sql>
<select id="selectEmsBatteryClusterList" parameterType="EmsBatteryCluster" resultMap="EmsBatteryClusterResult">
<include refid="selectEmsBatteryClusterVo"/>
<where>
<if test="workStatus != null and workStatus != ''"> and work_status = #{workStatus}</if>
<if test="pcsCommunicationStatus != null and pcsCommunicationStatus != ''"> and pcs_communication_status = #{pcsCommunicationStatus}</if>
<if test="emsCommunicationStatus != null and emsCommunicationStatus != ''"> and ems_communication_status = #{emsCommunicationStatus}</if>
<if test="clusterVoltage != null "> and cluster_voltage = #{clusterVoltage}</if>
<if test="chargeableCapacity != null "> and chargeable_capacity = #{chargeableCapacity}</if>
<if test="totalChargedCapacity != null "> and total_charged_capacity = #{totalChargedCapacity}</if>
<if test="clusterCurrent != null "> and cluster_current = #{clusterCurrent}</if>
<if test="dischargeableCapacity != null "> and dischargeable_capacity = #{dischargeableCapacity}</if>
<if test="totalDischargedCapacity != null "> and total_discharged_capacity = #{totalDischargedCapacity}</if>
<if test="soh != null "> and soh = #{soh}</if>
<if test="averageTemperature != null "> and average_temperature = #{averageTemperature}</if>
<if test="insulationResistance != null "> and insulation_resistance = #{insulationResistance}</if>
<if test="currentSoc != null "> and current_soc = #{currentSoc}</if>
<if test="siteId != null "> and site_id = #{siteId}</if>
<if test="deviceId != null "> and device_id = #{deviceId}</if>
</where>
</select>
<select id="selectEmsBatteryClusterById" parameterType="Long" resultMap="EmsBatteryClusterResult">
<include refid="selectEmsBatteryClusterVo"/>
where id = #{id}
</select>
<insert id="insertEmsBatteryCluster" parameterType="EmsBatteryCluster" useGeneratedKeys="true" keyProperty="id">
insert into ems_battery_cluster
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="workStatus != null">work_status,</if>
<if test="pcsCommunicationStatus != null">pcs_communication_status,</if>
<if test="emsCommunicationStatus != null">ems_communication_status,</if>
<if test="clusterVoltage != null">cluster_voltage,</if>
<if test="chargeableCapacity != null">chargeable_capacity,</if>
<if test="totalChargedCapacity != null">total_charged_capacity,</if>
<if test="clusterCurrent != null">cluster_current,</if>
<if test="dischargeableCapacity != null">dischargeable_capacity,</if>
<if test="totalDischargedCapacity != null">total_discharged_capacity,</if>
<if test="soh != null">soh,</if>
<if test="averageTemperature != null">average_temperature,</if>
<if test="insulationResistance != null">insulation_resistance,</if>
<if test="currentSoc != null">current_soc,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="remark != null">remark,</if>
<if test="siteId != null">site_id,</if>
<if test="deviceId != null">device_id,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="workStatus != null">#{workStatus},</if>
<if test="pcsCommunicationStatus != null">#{pcsCommunicationStatus},</if>
<if test="emsCommunicationStatus != null">#{emsCommunicationStatus},</if>
<if test="clusterVoltage != null">#{clusterVoltage},</if>
<if test="chargeableCapacity != null">#{chargeableCapacity},</if>
<if test="totalChargedCapacity != null">#{totalChargedCapacity},</if>
<if test="clusterCurrent != null">#{clusterCurrent},</if>
<if test="dischargeableCapacity != null">#{dischargeableCapacity},</if>
<if test="totalDischargedCapacity != null">#{totalDischargedCapacity},</if>
<if test="soh != null">#{soh},</if>
<if test="averageTemperature != null">#{averageTemperature},</if>
<if test="insulationResistance != null">#{insulationResistance},</if>
<if test="currentSoc != null">#{currentSoc},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="remark != null">#{remark},</if>
<if test="siteId != null">#{siteId},</if>
<if test="deviceId != null">#{deviceId},</if>
</trim>
</insert>
<update id="updateEmsBatteryCluster" parameterType="EmsBatteryCluster">
update ems_battery_cluster
<trim prefix="SET" suffixOverrides=",">
<if test="workStatus != null">work_status = #{workStatus},</if>
<if test="pcsCommunicationStatus != null">pcs_communication_status = #{pcsCommunicationStatus},</if>
<if test="emsCommunicationStatus != null">ems_communication_status = #{emsCommunicationStatus},</if>
<if test="clusterVoltage != null">cluster_voltage = #{clusterVoltage},</if>
<if test="chargeableCapacity != null">chargeable_capacity = #{chargeableCapacity},</if>
<if test="totalChargedCapacity != null">total_charged_capacity = #{totalChargedCapacity},</if>
<if test="clusterCurrent != null">cluster_current = #{clusterCurrent},</if>
<if test="dischargeableCapacity != null">dischargeable_capacity = #{dischargeableCapacity},</if>
<if test="totalDischargedCapacity != null">total_discharged_capacity = #{totalDischargedCapacity},</if>
<if test="soh != null">soh = #{soh},</if>
<if test="averageTemperature != null">average_temperature = #{averageTemperature},</if>
<if test="insulationResistance != null">insulation_resistance = #{insulationResistance},</if>
<if test="currentSoc != null">current_soc = #{currentSoc},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="siteId != null">site_id = #{siteId},</if>
<if test="deviceId != null">device_id = #{deviceId},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteEmsBatteryClusterById" parameterType="Long">
delete from ems_battery_cluster where id = #{id}
</delete>
<delete id="deleteEmsBatteryClusterByIds" parameterType="String">
delete from ems_battery_cluster where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
<select id="getBMSBatteryCluster" parameterType="Long" resultMap="EmsBatteryClusterResult">
<include refid="selectEmsBatteryClusterVo"/>
where site_id = #{siteId}
</select>
</mapper>

View File

@ -0,0 +1,151 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xzzn.ems.mapper.EmsBatteryStackMapper">
<resultMap type="EmsBatteryStack" id="EmsBatteryStackResult">
<result property="id" column="id" />
<result property="workStatus" column="work_status" />
<result property="pcsCommunicationStatus" column="pcs_communication_status" />
<result property="emsCommunicationStatus" column="ems_communication_status" />
<result property="totalVoltage" column="total_voltage" />
<result property="chargeableCapacity" column="chargeable_capacity" />
<result property="totalChargedCapacity" column="total_charged_capacity" />
<result property="totalCurrent" column="total_current" />
<result property="dischargeableCapacity" column="dischargeable_capacity" />
<result property="totalDischargedCapacity" column="total_discharged_capacity" />
<result property="soh" column="soh" />
<result property="averageTemperature" column="average_temperature" />
<result property="insulationResistance" column="insulation_resistance" />
<result property="currentSoc" column="current_soc" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="remark" column="remark" />
<result property="siteId" column="site_id" />
<result property="deviceId" column="device_id" />
</resultMap>
<sql id="selectEmsBatteryStackVo">
select id, work_status, pcs_communication_status, ems_communication_status, total_voltage, chargeable_capacity, total_charged_capacity, total_current, dischargeable_capacity, total_discharged_capacity, soh, average_temperature, insulation_resistance, current_soc, create_by, create_time, update_by, update_time, remark, site_id, device_id from ems_battery_stack
</sql>
<select id="selectEmsBatteryStackList" parameterType="EmsBatteryStack" resultMap="EmsBatteryStackResult">
<include refid="selectEmsBatteryStackVo"/>
<where>
<if test="workStatus != null and workStatus != ''"> and work_status = #{workStatus}</if>
<if test="pcsCommunicationStatus != null and pcsCommunicationStatus != ''"> and pcs_communication_status = #{pcsCommunicationStatus}</if>
<if test="emsCommunicationStatus != null and emsCommunicationStatus != ''"> and ems_communication_status = #{emsCommunicationStatus}</if>
<if test="totalVoltage != null "> and total_voltage = #{totalVoltage}</if>
<if test="chargeableCapacity != null "> and chargeable_capacity = #{chargeableCapacity}</if>
<if test="totalChargedCapacity != null "> and total_charged_capacity = #{totalChargedCapacity}</if>
<if test="totalCurrent != null "> and total_current = #{totalCurrent}</if>
<if test="dischargeableCapacity != null "> and dischargeable_capacity = #{dischargeableCapacity}</if>
<if test="totalDischargedCapacity != null "> and total_discharged_capacity = #{totalDischargedCapacity}</if>
<if test="soh != null "> and soh = #{soh}</if>
<if test="averageTemperature != null "> and average_temperature = #{averageTemperature}</if>
<if test="insulationResistance != null "> and insulation_resistance = #{insulationResistance}</if>
<if test="currentSoc != null "> and current_soc = #{currentSoc}</if>
<if test="siteId != null "> and site_id = #{siteId}</if>
<if test="deviceId != null "> and device_id = #{deviceId}</if>
</where>
</select>
<select id="selectEmsBatteryStackById" parameterType="Long" resultMap="EmsBatteryStackResult">
<include refid="selectEmsBatteryStackVo"/>
where id = #{id}
</select>
<insert id="insertEmsBatteryStack" parameterType="EmsBatteryStack" useGeneratedKeys="true" keyProperty="id">
insert into ems_battery_stack
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="workStatus != null">work_status,</if>
<if test="pcsCommunicationStatus != null">pcs_communication_status,</if>
<if test="emsCommunicationStatus != null">ems_communication_status,</if>
<if test="totalVoltage != null">total_voltage,</if>
<if test="chargeableCapacity != null">chargeable_capacity,</if>
<if test="totalChargedCapacity != null">total_charged_capacity,</if>
<if test="totalCurrent != null">total_current,</if>
<if test="dischargeableCapacity != null">dischargeable_capacity,</if>
<if test="totalDischargedCapacity != null">total_discharged_capacity,</if>
<if test="soh != null">soh,</if>
<if test="averageTemperature != null">average_temperature,</if>
<if test="insulationResistance != null">insulation_resistance,</if>
<if test="currentSoc != null">current_soc,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="remark != null">remark,</if>
<if test="siteId != null">site_id,</if>
<if test="deviceId != null">device_id,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="workStatus != null">#{workStatus},</if>
<if test="pcsCommunicationStatus != null">#{pcsCommunicationStatus},</if>
<if test="emsCommunicationStatus != null">#{emsCommunicationStatus},</if>
<if test="totalVoltage != null">#{totalVoltage},</if>
<if test="chargeableCapacity != null">#{chargeableCapacity},</if>
<if test="totalChargedCapacity != null">#{totalChargedCapacity},</if>
<if test="totalCurrent != null">#{totalCurrent},</if>
<if test="dischargeableCapacity != null">#{dischargeableCapacity},</if>
<if test="totalDischargedCapacity != null">#{totalDischargedCapacity},</if>
<if test="soh != null">#{soh},</if>
<if test="averageTemperature != null">#{averageTemperature},</if>
<if test="insulationResistance != null">#{insulationResistance},</if>
<if test="currentSoc != null">#{currentSoc},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="remark != null">#{remark},</if>
<if test="siteId != null">#{siteId},</if>
<if test="deviceId != null">#{deviceId},</if>
</trim>
</insert>
<update id="updateEmsBatteryStack" parameterType="EmsBatteryStack">
update ems_battery_stack
<trim prefix="SET" suffixOverrides=",">
<if test="workStatus != null">work_status = #{workStatus},</if>
<if test="pcsCommunicationStatus != null">pcs_communication_status = #{pcsCommunicationStatus},</if>
<if test="emsCommunicationStatus != null">ems_communication_status = #{emsCommunicationStatus},</if>
<if test="totalVoltage != null">total_voltage = #{totalVoltage},</if>
<if test="chargeableCapacity != null">chargeable_capacity = #{chargeableCapacity},</if>
<if test="totalChargedCapacity != null">total_charged_capacity = #{totalChargedCapacity},</if>
<if test="totalCurrent != null">total_current = #{totalCurrent},</if>
<if test="dischargeableCapacity != null">dischargeable_capacity = #{dischargeableCapacity},</if>
<if test="totalDischargedCapacity != null">total_discharged_capacity = #{totalDischargedCapacity},</if>
<if test="soh != null">soh = #{soh},</if>
<if test="averageTemperature != null">average_temperature = #{averageTemperature},</if>
<if test="insulationResistance != null">insulation_resistance = #{insulationResistance},</if>
<if test="currentSoc != null">current_soc = #{currentSoc},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="siteId != null">site_id = #{siteId},</if>
<if test="deviceId != null">device_id = #{deviceId},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteEmsBatteryStackById" parameterType="Long">
delete from ems_battery_stack where id = #{id}
</delete>
<delete id="deleteEmsBatteryStackByIds" parameterType="String">
delete from ems_battery_stack where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
<select id="selectEmsBatteryStackBySiteId" parameterType="Long" resultMap="EmsBatteryStackResult">
<include refid="selectEmsBatteryStackVo"/>
where site_id = #{siteId} order by update_time desc limit 1
</select>
</mapper>

View File

@ -254,4 +254,10 @@
) as tmp
group by dateMonth
</select>
<select id="getPcsDetailInfoBySiteId" parameterType="Long" resultMap="EmsPcsDataResult">
<include refid="selectEmsPcsDataVo"/>
where site_id = #{siteId}
order by data_update_time desc limit 1
</select>
</mapper>