修改
This commit is contained in:
@@ -763,7 +763,14 @@ public class MesToLmsServiceImpl implements MesToLmsService {
|
||||
JSONObject jo = new JSONObject();
|
||||
jo.put("point_code", down_point_code);
|
||||
jo.put("cut_rows", down_rows);
|
||||
if (del_rows.size() > 1) {
|
||||
if (del_rows.size() > 0) {
|
||||
if (up_rows.size() > 0){
|
||||
if (del_rows.size() == 1){
|
||||
jo.put("is_last", "0");
|
||||
}else {
|
||||
jo.put("is_last", "1");
|
||||
}
|
||||
}
|
||||
jo.put("is_last", "0");
|
||||
} else {
|
||||
jo.put("is_last", "1");
|
||||
|
||||
@@ -37,6 +37,13 @@ public class OutController {
|
||||
return new ResponseEntity<>(outService.confirm(whereJson), HttpStatus.OK);
|
||||
}
|
||||
|
||||
@PostMapping("/disuseConfirm")
|
||||
@Log("废箔下卷")
|
||||
@ApiOperation("废箔下卷")
|
||||
public ResponseEntity<Object> disuseConfirm(@RequestBody JSONObject whereJson) {
|
||||
return new ResponseEntity<>(outService.disuseConfirm(whereJson), HttpStatus.OK);
|
||||
}
|
||||
|
||||
@PostMapping("/conveyPointQuery")
|
||||
@Log("缓存点位查询")
|
||||
@ApiOperation("缓存点位查询")
|
||||
|
||||
@@ -19,6 +19,13 @@ public interface OutService {
|
||||
*/
|
||||
JSONObject confirm(JSONObject whereJson);
|
||||
|
||||
/**
|
||||
* 废箔下卷确认
|
||||
* @param whereJson /
|
||||
* @return JSONObject
|
||||
*/
|
||||
JSONObject disuseConfirm(JSONObject whereJson);
|
||||
|
||||
/**
|
||||
* 缓存点位查询
|
||||
* @param whereJson /
|
||||
|
||||
@@ -169,6 +169,43 @@ public class OutServiceImpl implements OutService {
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public JSONObject disuseConfirm(JSONObject whereJson) {
|
||||
String point_code = whereJson.getString("point_code");
|
||||
|
||||
//查询该点位对应的机台编号
|
||||
JSONObject cut_ivt = WQLObject.getWQLObject("ST_IVT_CutPointIvt").query("up_point_code ='" + point_code + "' OR down_point_code ='" + point_code + "'").uniqueResult(0);
|
||||
|
||||
if (ObjectUtil.isEmpty(cut_ivt)) {
|
||||
throw new BadRequestException("未查询到对应的分切机!");
|
||||
}
|
||||
|
||||
//查询该分切机邻近位置的空载具的输送线点位
|
||||
JSONObject empty_vehicle = WQL.getWO("PDA_02")
|
||||
.addParam("sort_seq", cut_ivt.getString("sort_seq"))
|
||||
.addParam("sql_str", " ORDER BY abs(" + cut_ivt.getString("sort_seq") + "-sort_seq),point_code")
|
||||
.addParam("product_area", cut_ivt.getString("product_area"))
|
||||
.addParam("point_location", cut_ivt.getString("point_location"))
|
||||
.addParam("flag", "3").process().uniqueResult(0);
|
||||
if (ObjectUtil.isEmpty(empty_vehicle)) {
|
||||
throw new BadRequestException("未查询到可用的空载具!");
|
||||
}
|
||||
|
||||
JSONObject jo = new JSONObject();
|
||||
jo.put("point_code1", point_code);
|
||||
jo.put("point_code2", empty_vehicle.getString("point_code"));
|
||||
jo.put("vehicle_code", "waste foil");
|
||||
jo.put("product_area", cut_ivt.getString("product_area"));
|
||||
//分切>输送线 子卷出站
|
||||
jo.put("task_type", "010404");
|
||||
cutTrussTask.createTask(jo);
|
||||
|
||||
JSONObject result = new JSONObject();
|
||||
result.put("message", "操作成功!");
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public JSONObject conveyPointQuery(JSONObject whereJson) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
|
||||
Reference in New Issue
Block a user