add:临时通道移库

This commit is contained in:
2023-05-18 17:37:02 +08:00
parent e8abec2f26
commit 1ab3878fe2
14 changed files with 675 additions and 61 deletions

View File

@@ -25,4 +25,8 @@ public interface AutoRiKuService {
* */
JSONObject getAllPoint();
/**
* 获取发货区
* */
JSONObject queryNum(JSONObject whereJson);
}

View File

@@ -209,4 +209,22 @@ public class AutoRiKuServiceImpl implements AutoRiKuService {
return jsonAll;
}
@Override
public JSONObject queryNum(JSONObject whereJson) {
WQLObject pointTab = WQLObject.getWQLObject("sch_base_point");
String layer_num = whereJson.getString("layer_num");
// 有货个数
JSONArray haveMoney = pointTab.query("layer_num = '" + layer_num + "' and point_type = '9' and IFNULL(vehicle_code,'')<>'' and is_delete = '0' and is_used = '1'").getResultJSONArray(0);
// 无货个数
JSONArray unMoney = pointTab.query("layer_num = '" + layer_num + "' and point_type = '9' and IFNULL(vehicle_code,'')='' and is_delete = '0' and is_used = '1'").getResultJSONArray(0);
JSONObject result = new JSONObject();
result.put("haveMoney",haveMoney.size());
result.put("unMoney",unMoney.size());
return result;
}
}

View File

@@ -37,4 +37,11 @@ public class AutoWebSocketRiKu {
return new ResponseEntity<>(data, HttpStatus.OK);
}
@PostMapping("/queryNum")
@Log("查询发货区")
@ApiOperation("查询发货区")
public ResponseEntity<Object> queryNum(@RequestBody JSONObject whereJson){
return new ResponseEntity<>(autoRiKuService.queryNum(whereJson), HttpStatus.OK);
}
}