优化
This commit is contained in:
@@ -211,8 +211,27 @@ public class ToWmsApiController {
|
||||
basProduct.setProductName(param.get("item_name").toString());
|
||||
basProduct.setPrice(param.get("item_desc").toString());
|
||||
basProduct.setSpec(param.get("item_spec").toString());
|
||||
basProduct.setUnit(param.get("inv_unit_no").toString());
|
||||
basProduct.setUnit(param.get("item_group_no").toString());
|
||||
basProduct.setParentId(param.get("item_group_no").toString());
|
||||
JSONArray param1 = JSONUtil.parseArray(param.get("packing_mode").toString());
|
||||
if(param1.size() > 0){
|
||||
basProduct.setSpare36(JSONUtil.parseObj(param1.get(0).toString()).get("length").toString());
|
||||
basProduct.setSpare37(JSONUtil.parseObj(param1.get(0).toString()).get("width").toString());
|
||||
basProduct.setSpare38(JSONUtil.parseObj(param1.get(0).toString()).get("heigth").toString());
|
||||
if(basProduct.getSpare36() != null && basProduct.getSpare37() != null){
|
||||
if("760".equals(basProduct.getSpare36()) && "960".equals(basProduct.getSpare37())){
|
||||
basProduct.setSpare10("1");
|
||||
} else if ("1000".equals(basProduct.getSpare36()) && "800".equals(basProduct.getSpare37())) {
|
||||
basProduct.setSpare10("2");
|
||||
} else if ("1130".equals(basProduct.getSpare36()) && "800".equals(basProduct.getSpare37())) {
|
||||
basProduct.setSpare10("3");
|
||||
} else if ("1130".equals(basProduct.getSpare36()) && "900".equals(basProduct.getSpare37())) {
|
||||
basProduct.setSpare10("4");
|
||||
} else{
|
||||
basProduct.setSpare10("5");
|
||||
}
|
||||
}
|
||||
}
|
||||
AjaxResult ajaxResult = toWmsService.receiveProduct(basProduct);
|
||||
RequestLog requestLog = requestLogService.getRequestLog(JSONUtil.toJsonStr(basProduct), "接收物料", ajaxResult);
|
||||
requestLogService.insertRequestLog(requestLog);
|
||||
@@ -249,6 +268,12 @@ public class ToWmsApiController {
|
||||
basProduct.setPrice(param.get("item_desc").toString());
|
||||
basProduct.setSpec(param.get("item_spec").toString());
|
||||
basProduct.setUnit(param.get("inv_unit_no").toString());
|
||||
JSONArray param1 = JSONUtil.parseArray(param.get("packing_mode").toString());
|
||||
if(param1.size() > 0){
|
||||
basProduct.setSpare36(JSONUtil.parseObj(param1.get(0).toString()).get("length").toString());
|
||||
basProduct.setSpare37(JSONUtil.parseObj(param1.get(0).toString()).get("width").toString());
|
||||
basProduct.setSpare38(JSONUtil.parseObj(param1.get(0).toString()).get("heigth").toString());
|
||||
}
|
||||
AjaxResult ajaxResult = toWmsService.InvalidProduct(basProduct);
|
||||
RequestLog requestLog = requestLogService.getRequestLog(JSONUtil.toJsonStr(basProduct), "作废物料", ajaxResult);
|
||||
requestLogService.insertRequestLog(requestLog);
|
||||
|
||||
Reference in New Issue
Block a user