From 24e585c2262175c6bf256fe7f9ed1b8492f388c3 Mon Sep 17 00:00:00 2001 From: zhenghaoyu Date: Mon, 3 Jul 2023 11:05:37 +0800 Subject: [PATCH] =?UTF-8?q?1.=E7=9A=AE=E9=98=BF=E8=AF=BA=E7=8A=B6=E6=80=81?= =?UTF-8?q?=E6=98=A0=E5=B0=84=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/PanFactoryDataServiceImpl.java | 23 ++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/pan/service/impl/PanFactoryDataServiceImpl.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/pan/service/impl/PanFactoryDataServiceImpl.java index e5e4ff5c5..98005b4a7 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/pan/service/impl/PanFactoryDataServiceImpl.java +++ b/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); 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); return Resp.fail(400,"当前数据的状态不推送"); } @@ -226,6 +226,8 @@ public class PanFactoryDataServiceImpl implements IPanFactoryDataService { orderStatusDTO.setLogiBillNo(supplyData.get("logiBillNo")); // orderStatusDTO.setLogiBillNo("GZ23060001"); + //修改状态映射 + orderStatusDTO.setStatus(statusName(orderStatusDTO.getStatus())); //判断数据是都已存在 @@ -272,6 +274,25 @@ public class PanFactoryDataServiceImpl implements IPanFactoryDataService { 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(){ Map map = new HashMap<>(); map.put("client_id",panFactoryProperties.getClientId());