opt:优化代码

This commit is contained in:
DESKTOP-5DIJMF9\admin
2025-04-01 22:06:23 +08:00
parent 1fe6dc7104
commit 18fd707820
2 changed files with 6 additions and 2 deletions

View File

@@ -1707,7 +1707,7 @@ public class MesToLmsServiceImpl implements MesToLmsService {
if (ObjectUtil.isEmpty(Type)) {
throw new BadRequestException("传入的类型不能为空!");
}
//表处设备表
JSONObject device_jo = WQLObject.getWQLObject("st_ivt_stpointivt").query("ext_code = '" + ResourceName + "'").uniqueResult(0);
if (ObjectUtil.isEmpty(device_jo)) {
throw new BadRequestException("未查询到[" + ResourceName + "]应的表处机设备!");
@@ -1735,10 +1735,14 @@ public class MesToLmsServiceImpl implements MesToLmsService {
form.put("acs_task_type", "3");
} else {
//取满取空放满放空
//满轴
form.put("point_code1", jsonCoolIvt.getString("full_point_code"));
//放满
form.put("point_code2", device_jo.getString("up_point_code") + "_M");
//取空
form.put("point_code3", device_jo.getString("up_point_code") + "_K");
//判断对应空轴点位是否为空,为空用当前点位,不为空查询其他点位
//01没有空轴
if (jsonCoolIvt.getString("empty_point_status").equals("01")) {
form.put("point_code4", jsonCoolIvt.getString("empty_point_code"));
} else {

View File

@@ -340,7 +340,7 @@ IF 输入.flag = "6"
FROM
ST_IVT_CoolPointIvt ivt
WHERE
ivt.empty_point_status = '02'
ivt.empty_point_status = '01'
AND ivt.point_type = '1'
AND
ivt.is_used = '1'