代码更新

This commit is contained in:
2022-12-13 10:44:52 +08:00
parent fbe10f98b7
commit e0f1decfda
8 changed files with 65 additions and 4 deletions

View File

@@ -31,6 +31,13 @@ public class BakingController {
return new ResponseEntity<>(bakingService.ovenInAndOut(whereJson),HttpStatus.OK);
}
@PostMapping("/query")
@Log("查询")
@ApiOperation("查询")
public ResponseEntity<Object> query(@RequestBody JSONObject whereJson) {
return new ResponseEntity<>(bakingService.query(whereJson),HttpStatus.OK);
}
@PostMapping("/inCoolIvt")
@Log("入冷却")
@ApiOperation("入冷却")

View File

@@ -21,4 +21,5 @@ public interface BakingService {
JSONObject release(JSONObject whereJson);
JSONObject query(JSONObject whereJson);
}

View File

@@ -461,4 +461,35 @@ public class BakingServiceImpl implements BakingService {
public JSONObject release(JSONObject whereJson) {
return null;
}
@Override
public JSONObject query(JSONObject whereJson) {
WQLObject coolIvtTab = WQLObject.getWQLObject("ST_IVT_CoolPointIvt");
WQLObject hotIvtTab = WQLObject.getWQLObject("ST_IVT_HotPointIvt");
WQLObject pointIvtTab = WQLObject.getWQLObject("sch_base_point");
String point_code = whereJson.getString("point_code");
JSONObject json = new JSONObject();
JSONObject jsonCool = coolIvtTab.query("full_point_code = '" + point_code + "'").uniqueResult(0);
if (ObjectUtil.isNotEmpty(jsonCool.getString("container_name"))) {
json.put("container_name", jsonCool.getString("container_name"));
} else {
JSONObject jsonHot = hotIvtTab.query("point_code = '" + point_code + "'").uniqueResult(0);
if (ObjectUtil.isNotEmpty(jsonHot.getString("container_name"))) {
json.put("container_name", jsonHot.getString("container_name"));
} else {
JSONObject jsonPoint = pointIvtTab.query("point_code = '" + point_code + "'").uniqueResult(0);
if (ObjectUtil.isNotEmpty(jsonPoint.getString("material_code"))) {
json.put("container_name", jsonPoint.getString("material_code"));
} else {
json.put("container_name", "");
}
}
}
JSONObject result = new JSONObject();
result.put("data",json);
result.put("message","操作成功!");
return result;
}
}

View File

@@ -56,7 +56,7 @@ public class EmptyVehicleServiceImpl implements EmptyVehicleService {
String option = whereJson.getString("option");
JSONObject point_jo = WQLObject.getWQLObject("st_ivt_coolpointivt").query("empty_point_code = '"+point_code+"'").uniqueResult(0);
if (ObjectUtil.isEmpty(point_jo)){
throw new BadRequestException("未查询到对应的点位设备");
throw new BadRequestException("空轴点位不存在");
}
if (option.equals("0")){
point_jo.put("empty_vehicle_code","");

View File

@@ -89,6 +89,7 @@
OPTION 输入.search <> ""
(vehicle_code like 输入.search or
vehicle_code2 like 输入.search or
point_code1 like 输入.search or
point_code2 like 输入.search or
point_code3 like 输入.search or

View File

@@ -47,6 +47,7 @@ public class HotPointIvtServiceImpl implements HotPointIvtService {
map.put("is_used", whereJson.get("is_used"));
map.put("begin_time", whereJson.get("begin_time"));
map.put("end_time", whereJson.get("end_time"));
map.put("point_location", whereJson.get("point_location"));
JSONObject json = WQL.getWO("ST_IVT_HOTPOINTIVT").addParamMap(map).pageQuery(WqlUtil.getHttpContext(page), "product_area,point_code");
return json;

View File

@@ -26,6 +26,7 @@
输入.task_code TYPEAS s_string
输入.start_point_code TYPEAS s_string
输入.next_point_code TYPEAS s_string
输入.point_location TYPEAS s_string
[临时表]
@@ -57,6 +58,9 @@
st_ivt_hotpointivt hot
WHERE
1=1
OPTION 输入.point_location <> ""
point_location = 输入.point_location
ENDOPTION
OPTION 输入.point_code <> ""
point_code LIKE 输入.point_code
ENDOPTION