Browse Source

1.皮阿诺状态映射修改

test
zhenghaoyu 2 years ago
parent
commit
24e585c226
  1. 23
      blade-service/logpm-factory/src/main/java/com/logpm/factory/pan/service/impl/PanFactoryDataServiceImpl.java

23
blade-service/logpm-factory/src/main/java/com/logpm/factory/pan/service/impl/PanFactoryDataServiceImpl.java

@ -197,7 +197,7 @@ public class PanFactoryDataServiceImpl implements IPanFactoryDataService {
panOrderStatusLogService.save(panOrderStatusLog); panOrderStatusLogService.save(panOrderStatusLog);
String status = orderStatusDTO.getStatus(); String status = orderStatusDTO.getStatus();
if("2".equals(status)||"5".equals(status)||"8".equals(status)||"9".equals(status)){ if("1".equals(status)||"2".equals(status)||"5".equals(status)||"6".equals(status)||"8".equals(status)||"9".equals(status)){
logger.info("#############handleStatusData: 当前数据的状态不推送 status={}",status); logger.info("#############handleStatusData: 当前数据的状态不推送 status={}",status);
return Resp.fail(400,"当前数据的状态不推送"); return Resp.fail(400,"当前数据的状态不推送");
} }
@ -226,6 +226,8 @@ public class PanFactoryDataServiceImpl implements IPanFactoryDataService {
orderStatusDTO.setLogiBillNo(supplyData.get("logiBillNo")); orderStatusDTO.setLogiBillNo(supplyData.get("logiBillNo"));
// orderStatusDTO.setLogiBillNo("GZ23060001"); // orderStatusDTO.setLogiBillNo("GZ23060001");
//修改状态映射
orderStatusDTO.setStatus(statusName(orderStatusDTO.getStatus()));
//判断数据是都已存在 //判断数据是都已存在
@ -272,6 +274,25 @@ public class PanFactoryDataServiceImpl implements IPanFactoryDataService {
return Resp.success("SUCCESS"); return Resp.success("SUCCESS");
} }
private String statusName(String status){
String statusName = null;
switch (status){
case "4":
statusName = "入库";
break;
case "3":
statusName = "装车";
break;
case "7":
statusName = "签收";
break;
default:
logger.info("###########statusName: 未知的类型");
}
return statusName;
}
private String getPanToken(){ private String getPanToken(){
Map<String,Object> map = new HashMap<>(); Map<String,Object> map = new HashMap<>();
map.put("client_id",panFactoryProperties.getClientId()); map.put("client_id",panFactoryProperties.getClientId());

Loading…
Cancel
Save