新增运行策略轮询功能
This commit is contained in:
197
ems-system/src/main/java/com/xzzn/ems/domain/EmsStrategyLog.java
Normal file
197
ems-system/src/main/java/com/xzzn/ems/domain/EmsStrategyLog.java
Normal file
@ -0,0 +1,197 @@
|
||||
package com.xzzn.ems.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.xzzn.common.annotation.Excel;
|
||||
import com.xzzn.common.core.domain.BaseEntity;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 策略运行日志对象 ems_strategy_log
|
||||
*
|
||||
* @author xzzn
|
||||
* @date 2025-12-26
|
||||
*/
|
||||
public class EmsStrategyLog extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** $column.columnComment */
|
||||
private Long id;
|
||||
|
||||
/** 策略ID */
|
||||
@Excel(name = "策略ID")
|
||||
private Long strategyId;
|
||||
|
||||
/** 模版id */
|
||||
@Excel(name = "模版id")
|
||||
private String templateId;
|
||||
|
||||
/** 站点id */
|
||||
@Excel(name = "站点id")
|
||||
private String siteId;
|
||||
|
||||
/** 设备唯一标识符 */
|
||||
@Excel(name = "设备唯一标识符")
|
||||
private String deviceId;
|
||||
|
||||
/** 开始时间 */
|
||||
@JsonFormat(pattern = "HH:mm")
|
||||
@Excel(name = "开始时间", width = 30, dateFormat = "HH:mm")
|
||||
private Date startTime;
|
||||
|
||||
/** 结束时间 */
|
||||
@JsonFormat(pattern = "HH:mm")
|
||||
@Excel(name = "结束时间", width = 30, dateFormat = "HH:mm")
|
||||
private Date endTime;
|
||||
|
||||
/** 功率 (kW) */
|
||||
@Excel(name = "功率 (kW)")
|
||||
private BigDecimal chargeDischargePower;
|
||||
|
||||
/** 充电状态,如“1-充电”、“2-待机”、“3-放电” */
|
||||
@Excel(name = "充电状态,如“1-充电”、“2-待机”、“3-放电”")
|
||||
private String chargeStatus;
|
||||
|
||||
/** 执行时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "执行时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date executionDate;
|
||||
|
||||
/** 防逆流, 1-是、0-否 */
|
||||
@Excel(name = "防逆流, 1-是、0-否")
|
||||
private Integer antiReverse;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setStrategyId(Long strategyId)
|
||||
{
|
||||
this.strategyId = strategyId;
|
||||
}
|
||||
|
||||
public Long getStrategyId()
|
||||
{
|
||||
return strategyId;
|
||||
}
|
||||
|
||||
public void setTemplateId(String templateId)
|
||||
{
|
||||
this.templateId = templateId;
|
||||
}
|
||||
|
||||
public String getTemplateId()
|
||||
{
|
||||
return templateId;
|
||||
}
|
||||
|
||||
public void setSiteId(String siteId)
|
||||
{
|
||||
this.siteId = siteId;
|
||||
}
|
||||
|
||||
public String getSiteId()
|
||||
{
|
||||
return siteId;
|
||||
}
|
||||
|
||||
public String getDeviceId() {
|
||||
return deviceId;
|
||||
}
|
||||
|
||||
public void setDeviceId(String deviceId) {
|
||||
this.deviceId = deviceId;
|
||||
}
|
||||
|
||||
public void setStartTime(Date startTime)
|
||||
{
|
||||
this.startTime = startTime;
|
||||
}
|
||||
|
||||
public Date getStartTime()
|
||||
{
|
||||
return startTime;
|
||||
}
|
||||
|
||||
public void setEndTime(Date endTime)
|
||||
{
|
||||
this.endTime = endTime;
|
||||
}
|
||||
|
||||
public Date getEndTime()
|
||||
{
|
||||
return endTime;
|
||||
}
|
||||
|
||||
public void setChargeDischargePower(BigDecimal chargeDischargePower)
|
||||
{
|
||||
this.chargeDischargePower = chargeDischargePower;
|
||||
}
|
||||
|
||||
public BigDecimal getChargeDischargePower()
|
||||
{
|
||||
return chargeDischargePower;
|
||||
}
|
||||
|
||||
public void setChargeStatus(String chargeStatus)
|
||||
{
|
||||
this.chargeStatus = chargeStatus;
|
||||
}
|
||||
|
||||
public String getChargeStatus()
|
||||
{
|
||||
return chargeStatus;
|
||||
}
|
||||
|
||||
public void setExecutionDate(Date executionDate)
|
||||
{
|
||||
this.executionDate = executionDate;
|
||||
}
|
||||
|
||||
public Date getExecutionDate()
|
||||
{
|
||||
return executionDate;
|
||||
}
|
||||
|
||||
public Integer getAntiReverse() {
|
||||
return antiReverse;
|
||||
}
|
||||
|
||||
public void setAntiReverse(Integer antiReverse) {
|
||||
this.antiReverse = antiReverse;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("strategyId", getStrategyId())
|
||||
.append("templateId", getTemplateId())
|
||||
.append("siteId", getSiteId())
|
||||
.append("deviceId", getDeviceId())
|
||||
.append("antiReverse", getAntiReverse())
|
||||
.append("startTime", getStartTime())
|
||||
.append("endTime", getEndTime())
|
||||
.append("chargeDischargePower", getChargeDischargePower())
|
||||
.append("chargeStatus", getChargeStatus())
|
||||
.append("executionDate", getExecutionDate())
|
||||
.append("antiReverse", getAntiReverse())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -1,10 +1,18 @@
|
||||
package com.xzzn.ems.mapper;
|
||||
|
||||
import com.xzzn.ems.domain.EmsPcsData;
|
||||
import com.xzzn.ems.domain.vo.DateSearchRequest;
|
||||
import com.xzzn.ems.domain.vo.ElectricIndexList;
|
||||
import com.xzzn.ems.domain.vo.EnergyStoragePowVo;
|
||||
import com.xzzn.ems.domain.vo.PcsDetailInfoVo;
|
||||
import com.xzzn.ems.domain.vo.PcsMaxTempVo;
|
||||
import com.xzzn.ems.domain.vo.PcsStatisListVo;
|
||||
import com.xzzn.ems.domain.vo.SiteMonitorDataVo;
|
||||
import com.xzzn.ems.domain.vo.SiteMonitorRunningHeadInfoVo;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import com.xzzn.ems.domain.EmsPcsData;
|
||||
import com.xzzn.ems.domain.vo.*;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
@ -132,4 +140,6 @@ public interface EmsPcsDataMapper
|
||||
public List<PcsMaxTempVo> getFXMaxTemp(@Param("siteId")String siteId, @Param("startDate")Date startDate, @Param("endDate")Date endDate);
|
||||
// 实时运行-dds-pcs最高温度
|
||||
public List<PcsMaxTempVo> getDDSMaxTemp(@Param("siteId")String siteId, @Param("startDate")Date startDate, @Param("endDate")Date endDate);
|
||||
|
||||
List<EmsPcsData> getSitePcsDataInfo(@Param("siteId") String siteId);
|
||||
}
|
||||
|
||||
@ -0,0 +1,62 @@
|
||||
package com.xzzn.ems.mapper;
|
||||
|
||||
import com.xzzn.ems.domain.EmsStrategyLog;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 策略运行日志Mapper接口
|
||||
*
|
||||
* @author xzzn
|
||||
* @date 2025-12-26
|
||||
*/
|
||||
public interface EmsStrategyLogMapper
|
||||
{
|
||||
/**
|
||||
* 查询策略运行日志
|
||||
*
|
||||
* @param id 策略运行日志主键
|
||||
* @return 策略运行日志
|
||||
*/
|
||||
public EmsStrategyLog selectEmsStrategyLogById(Long id);
|
||||
|
||||
/**
|
||||
* 查询策略运行日志列表
|
||||
*
|
||||
* @param emsStrategyLog 策略运行日志
|
||||
* @return 策略运行日志集合
|
||||
*/
|
||||
public List<EmsStrategyLog> selectEmsStrategyLogList(EmsStrategyLog emsStrategyLog);
|
||||
|
||||
/**
|
||||
* 新增策略运行日志
|
||||
*
|
||||
* @param emsStrategyLog 策略运行日志
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertEmsStrategyLog(EmsStrategyLog emsStrategyLog);
|
||||
|
||||
/**
|
||||
* 修改策略运行日志
|
||||
*
|
||||
* @param emsStrategyLog 策略运行日志
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateEmsStrategyLog(EmsStrategyLog emsStrategyLog);
|
||||
|
||||
/**
|
||||
* 删除策略运行日志
|
||||
*
|
||||
* @param id 策略运行日志主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteEmsStrategyLogById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除策略运行日志
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteEmsStrategyLogByIds(Long[] ids);
|
||||
}
|
||||
@ -1,8 +1,10 @@
|
||||
package com.xzzn.ems.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.xzzn.ems.domain.EmsStrategyTimeConfig;
|
||||
import com.xzzn.ems.domain.vo.StrategyTimeConfigVo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
@ -70,6 +72,9 @@ public interface EmsStrategyTimeConfigMapper
|
||||
// 获取该策略下的时间配置
|
||||
List<EmsStrategyTimeConfig> getAllTimeConfigByTempId(String templateId);
|
||||
|
||||
// 获取指定月份和策略下的时间配置
|
||||
List<EmsStrategyTimeConfig> getTimeConfigByTempIdAndMonth(@Param("templateId") String templateId, @Param("month") int month);
|
||||
|
||||
// 设置该模版的时间配置为待下发
|
||||
public void updateTimeConfigWaitingPost(String templateId);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user