Commit 5996f639 authored by ZWT's avatar ZWT

feat(零碳): 长庆

1.修复登录页面登录接口验证码输入后不需要验证直接能登录的问题;
2.长庆演示,首页展示大屏功能修改,修改线路详情接口,增加查询日平均用电量逻辑,同时重构查询日产液量和日发电量逻辑,更新接口文档并完成接口冒烟测试,同时生成用例;
3.长庆极短期间开优化随动算法功能开发,设置自定义参数,初步完成极短时间,间开时间段优化测试功能;
4.间开制度管理模块,间开制度关联井口信息表表结构修改,增加"单次最高开井时长(h)","单次最低开井时长(h)","单次最高关井时长(h)","单次最低关井时长(h)"字段,同时修改数据表对应代码实体及表单参数,修改部分相关模块功能查询修改逻辑;

BREAKING CHANGE: 无

Closes 无

[skip ci]
parent 9f5e56d1
......@@ -162,7 +162,8 @@ public class SpaceOptimizeShortPeriodService extends SpaceOptimizeBaseService {
int[] ladder = {10, 5, 3, 1};
for (SpaceInstitutionDetailEnt detail : detailEntList) {
//创建记录
periodId = this.createOptimizePeriod(periodDTOList, detail.getId(), detail.getLineId(), BaseUtils.getExecutionCycleForCalibration(startDate, optimizeDate), optimizeDate);
periodId = this.createOptimizePeriod(periodDTOList, detail.getId(), detail.getLineId(),
BaseUtils.getExecutionCycleForCalibration(startDate, startDate), startDate);
//查预测光伏出力
powerList = this.getAveragePowerHalfHour(context, DynamicQueryPlantPredictedPowerInput.builder()
.plantIds(plantIdsMap.get(detail.getLineId()))
......@@ -679,44 +680,6 @@ public class SpaceOptimizeShortPeriodService extends SpaceOptimizeBaseService {
});
}
/**
* 加时
*
* @param durationDTO 持续时间dto
* @param endTime 结束时间
* @param minute 分钟
*/
private void overtime(SpaceOptimizeDurationDTO durationDTO, DateTime endTime, int minute) {
//判断向前补还是向后补
if (DateUtil.compare(durationDTO.getOpenTime(), endTime) == 0) {
//向前补
durationDTO.setOpenTime(DateUtil.offsetMinute(durationDTO.getOpenTime(), -minute));
} else {
//向后补
durationDTO.setCloseTime(DateUtil.offsetMinute(durationDTO.getCloseTime(), minute));
}
}
/**
* 通过时段类型获取权重
*
* @param periodTypeKey 周期类型键
* @return int
*/
private int getWeightByPeriodTypeKey(String periodTypeKey) {
switch (periodTypeKey) {
case "LOW":
return 5;
case "PEACE":
return 3;
case "PEAK":
return 1;
case "RUSH":
default:
return 0;
}
}
/**
* 极短期间开开优化--分页列表
*
......@@ -835,4 +798,42 @@ public class SpaceOptimizeShortPeriodService extends SpaceOptimizeBaseService {
return XPageResult.success(XCopyUtils.copyNewList(pageInfo.getList(), QuerySpaceOptimizeShortWellheadViewOutput.class),
input, pageInfo.getTotal());
}
/**
* 加时
*
* @param durationDTO 持续时间dto
* @param endTime 结束时间
* @param minute 分钟
*/
private void overtime(SpaceOptimizeDurationDTO durationDTO, DateTime endTime, int minute) {
//判断向前补还是向后补
if (DateUtil.compare(durationDTO.getOpenTime(), endTime) == 0) {
//向前补
durationDTO.setOpenTime(DateUtil.offsetMinute(durationDTO.getOpenTime(), -minute));
} else {
//向后补
durationDTO.setCloseTime(DateUtil.offsetMinute(durationDTO.getCloseTime(), minute));
}
}
/**
* 通过时段类型获取权重
*
* @param periodTypeKey 周期类型键
* @return int
*/
private int getWeightByPeriodTypeKey(String periodTypeKey) {
switch (periodTypeKey) {
case "LOW":
return 5;
case "PEACE":
return 3;
case "PEAK":
return 1;
case "RUSH":
default:
return 0;
}
}
}
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment