|
|
@ -53,7 +53,7 @@ public class CleanStartCommand extends BaseCommandHandler { |
|
|
|
Double height = cmdDTO.getDoubleParam("height");//针头下降高度 |
|
|
|
Double volume = cmdDTO.getDoubleParam("volume");//加水的量 |
|
|
|
Integer maxCycles = systemConfigService.getSystemConfigIntegerByCode(SystemConfigCode.cycle_clean_max);//获取最大清洁次数配置 |
|
|
|
Assert.isTrue(cycle != null && cycle > 0 && cycle < maxCycles && height < 51 && volume != null, () -> new AppException(ResultCode.INVALID_PARAMETER));//清洁次数不为空 切清洁次数大于0 |
|
|
|
Assert.isTrue(cycle != null && cycle > 0 && cycle < maxCycles && height < 55 && volume != null, () -> new AppException(ResultCode.INVALID_PARAMETER));//清洁次数不为空 切清洁次数大于0 |
|
|
|
Solutions solutions = solutionsService.getByCode(SolutionCode.water.name()); |
|
|
|
double waterScale = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.valueOf(solutions.getCode()));//水转换系数 |
|
|
|
double cleanWaterVolume = volume * waterScale;//清洁时加水的量 |
|
|
|