|  | @@ -135,15 +135,28 @@ public class ApiOrderController extends ApiBaseAction {
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |          //查询物流轨迹
 | 
	
		
			
				|  |  |          List<Map> mapList = new ArrayList<>();
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -        if((orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_10.getItem()) ||
 | 
	
		
			
				|  |  | -                orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_02.getItem()))){
 | 
	
		
			
				|  |  | -            Map map = new HashMap();
 | 
	
		
			
				|  |  | -            map.put("AcceptStation", "交易完成,用户已提走");
 | 
	
		
			
				|  |  | -            mapList.add(map);
 | 
	
		
			
				|  |  | -        }
 | 
	
		
			
				|  |  |          OrderProcessRecordEntity entity = orderProcessRecordService.queryObjectByOrderSn(orderInfo.getOrder_sn());
 | 
	
		
			
				|  |  |          if (entity != null) {
 | 
	
		
			
				|  |  | +            if((orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_10.getItem()) ||
 | 
	
		
			
				|  |  | +                    orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_02.getItem()))){
 | 
	
		
			
				|  |  | +                Map map = new HashMap();
 | 
	
		
			
				|  |  | +                map.put("AcceptStation", "交易完成,用户已提走");
 | 
	
		
			
				|  |  | +                mapList.add(map);
 | 
	
		
			
				|  |  | +            }else{
 | 
	
		
			
				|  |  | +                if (!StringUtils.isEmpty(orderInfo.getShipping_code()) && !StringUtils.isEmpty(orderInfo.getShipping_no()) &&entity.getShipmentSuccTime()!=null) {
 | 
	
		
			
				|  |  | +                    JSONObject Traces = apiKdniaoService.getOrderTracesByJson(orderInfo.getShipping_code(), orderInfo.getShipping_no());
 | 
	
		
			
				|  |  | +                    if (Traces != null) {
 | 
	
		
			
				|  |  | +                        mapList = (List<Map>) Traces.get("Traces");
 | 
	
		
			
				|  |  | +                        String State = (String) Traces.get("State"); //物流状态:2-在途中,3-签收,4-问题件
 | 
	
		
			
				|  |  | +                        if (Dict.logisticsStatus.item_0.getItem().equalsIgnoreCase(State)) {
 | 
	
		
			
				|  |  | +                            Map noDataMap = new HashMap();
 | 
	
		
			
				|  |  | +                            noDataMap.put("AcceptTime", "");
 | 
	
		
			
				|  |  | +                            noDataMap.put("AcceptStation", Traces.get("Reason"));
 | 
	
		
			
				|  |  | +                            mapList.add(noDataMap);
 | 
	
		
			
				|  |  | +                        }
 | 
	
		
			
				|  |  | +                    }
 | 
	
		
			
				|  |  | +                }
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  |              if (Dict.isSend.item_1.getItem().equalsIgnoreCase(entity.getIsCustomsSend()) && entity.getShipmentSuccTime() != null) {
 | 
	
		
			
				|  |  |                  Map map = new HashMap();
 | 
	
		
			
				|  |  |                  map.put("AcceptTime", new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(entity.getShipmentSuccTime()));
 | 
	
	
		
			
				|  | @@ -174,22 +187,6 @@ public class ApiOrderController extends ApiBaseAction {
 | 
	
		
			
				|  |  |                  map.put("AcceptStation", "订单提交成功");
 | 
	
		
			
				|  |  |                  mapList.add(map);
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -            if(!orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_10.getItem())){
 | 
	
		
			
				|  |  | -                if (!StringUtils.isEmpty(orderInfo.getShipping_code()) && !StringUtils.isEmpty(orderInfo.getShipping_no()) &&entity.getShipmentSuccTime()!=null) {
 | 
	
		
			
				|  |  | -                    JSONObject Traces = apiKdniaoService.getOrderTracesByJson(orderInfo.getShipping_code(), orderInfo.getShipping_no());
 | 
	
		
			
				|  |  | -                    if (Traces != null) {
 | 
	
		
			
				|  |  | -                        mapList = (List<Map>) Traces.get("Traces");
 | 
	
		
			
				|  |  | -                        String State = (String) Traces.get("State"); //物流状态:2-在途中,3-签收,4-问题件
 | 
	
		
			
				|  |  | -                        if (Dict.logisticsStatus.item_0.getItem().equalsIgnoreCase(State)) {
 | 
	
		
			
				|  |  | -                            Map noDataMap = new HashMap();
 | 
	
		
			
				|  |  | -                            noDataMap.put("AcceptTime", "");
 | 
	
		
			
				|  |  | -                            noDataMap.put("AcceptStation", Traces.get("Reason"));
 | 
	
		
			
				|  |  | -                            mapList.add(noDataMap);
 | 
	
		
			
				|  |  | -                        }
 | 
	
		
			
				|  |  | -                    }
 | 
	
		
			
				|  |  | -                }
 | 
	
		
			
				|  |  | -            }
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          resultObj.put("wuliu", mapList != null && mapList.size() > 0 ? mapList.get(0) : null);
 | 
	
		
			
				|  |  |  
 | 
	
	
		
			
				|  | @@ -321,38 +318,48 @@ public class ApiOrderController extends ApiBaseAction {
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          List<WuliuVo> wuliuList = new ArrayList<WuliuVo>();
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -        if((orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_10.getItem())
 | 
	
		
			
				|  |  | -                || orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_02.getItem()))
 | 
	
		
			
				|  |  | -                && orderInfo.getOrder_status() == Integer.parseInt(Dict.orderStatus.item_301.getItem())){
 | 
	
		
			
				|  |  | -            WuliuVo vo = new WuliuVo();
 | 
	
		
			
				|  |  | -            vo.setAcceptStation("交易完成,用户已提走");
 | 
	
		
			
				|  |  | -            wuliuList.add(vo);
 | 
	
		
			
				|  |  | -        }
 | 
	
		
			
				|  |  | -        if(!orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_10.getItem())) {
 | 
	
		
			
				|  |  | -            if (!StringUtils.isEmpty(orderInfo.getShipping_code()) && !StringUtils.isEmpty(orderInfo.getShipping_no())) {
 | 
	
		
			
				|  |  | -                // 快递
 | 
	
		
			
				|  |  | -                JSONObject Traces = apiKdniaoService.getOrderTracesByJson(orderInfo.getShipping_code(), orderInfo.getShipping_no());
 | 
	
		
			
				|  |  | -                List<Map> mapList = (List<Map>) Traces.get("Traces");
 | 
	
		
			
				|  |  | -                for (int i = 0; i < mapList.size(); i++) {
 | 
	
		
			
				|  |  | -                    WuliuVo vo = new WuliuVo();
 | 
	
		
			
				|  |  | -                    vo.setAcceptTime((String) mapList.get(i).get("AcceptTime"));
 | 
	
		
			
				|  |  | -                    vo.setAcceptStation((String) mapList.get(i).get("AcceptStation"));
 | 
	
		
			
				|  |  | -                    wuliuList.add(vo);
 | 
	
		
			
				|  |  | -                }
 | 
	
		
			
				|  |  | +        OrderProcessRecordEntity entity = orderProcessRecordService.queryObjectByOrderSn(orderInfo.getOrder_sn());
 | 
	
		
			
				|  |  | +        if(entity !=null){
 | 
	
		
			
				|  |  | +            if(orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_10.getItem())
 | 
	
		
			
				|  |  | +                    || orderInfo.getOrderBizType().equalsIgnoreCase(Dict.orderBizType.item_02.getItem())){
 | 
	
		
			
				|  |  | +                WuliuVo vo = new WuliuVo();
 | 
	
		
			
				|  |  | +                vo.setAcceptStation("交易完成,用户已提走");
 | 
	
		
			
				|  |  | +                wuliuList.add(vo);
 | 
	
		
			
				|  |  | +            }else {
 | 
	
		
			
				|  |  | +                if (!StringUtils.isEmpty(orderInfo.getShipping_code()) && !StringUtils.isEmpty(orderInfo.getShipping_no()) && entity.getShipmentSuccTime() != null) {
 | 
	
		
			
				|  |  | +                    // 快递
 | 
	
		
			
				|  |  | +                    JSONObject Traces = apiKdniaoService.getOrderTracesByJson(orderInfo.getShipping_code(), orderInfo.getShipping_no());
 | 
	
		
			
				|  |  | +                    List<Map> mapList = (List<Map>) Traces.get("Traces");
 | 
	
		
			
				|  |  | +                    for (int i = 0; i < mapList.size(); i++) {
 | 
	
		
			
				|  |  | +                        WuliuVo vo = new WuliuVo();
 | 
	
		
			
				|  |  | +                        vo.setAcceptTime((String) mapList.get(i).get("AcceptTime"));
 | 
	
		
			
				|  |  | +                        vo.setAcceptStation((String) mapList.get(i).get("AcceptStation"));
 | 
	
		
			
				|  |  | +                        wuliuList.add(vo);
 | 
	
		
			
				|  |  | +                    }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -                String State = (String) Traces.get("State"); //物流状态:2-在途中,3-签收,4-问题件
 | 
	
		
			
				|  |  | -                String Reason = (String) Traces.get("Reason");
 | 
	
		
			
				|  |  | -                if (Dict.logisticsStatus.item_0.getItem().equalsIgnoreCase(State)) {
 | 
	
		
			
				|  |  | -                    WuliuVo wuliuVo = new WuliuVo();
 | 
	
		
			
				|  |  | -                    wuliuVo.setAcceptStation(Reason);
 | 
	
		
			
				|  |  | -                    wuliuList.add(wuliuVo);
 | 
	
		
			
				|  |  | +                    String State = (String) Traces.get("State"); //物流状态:2-在途中,3-签收,4-问题件
 | 
	
		
			
				|  |  | +                    String Reason = (String) Traces.get("Reason");
 | 
	
		
			
				|  |  | +                    if (Dict.logisticsStatus.item_0.getItem().equalsIgnoreCase(State)) {
 | 
	
		
			
				|  |  | +                        WuliuVo wuliuVo = new WuliuVo();
 | 
	
		
			
				|  |  | +                        wuliuVo.setAcceptStation(Reason);
 | 
	
		
			
				|  |  | +                        wuliuList.add(wuliuVo);
 | 
	
		
			
				|  |  | +                    }
 | 
	
		
			
				|  |  | +                    map.put("State", Traces.get("State")); //物流状态:2-在途中,3-签收,4-问题件
 | 
	
		
			
				|  |  | +                    map.put("Reason", Traces.get("Reason"));
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  | -                map.put("State", Traces.get("State")); //物流状态:2-在途中,3-签收,4-问题件
 | 
	
		
			
				|  |  | -                map.put("Reason", Traces.get("Reason"));
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  | -        }
 | 
	
		
			
				|  |  | -        OrderProcessRecordEntity entity = orderProcessRecordService.queryObjectByOrderSn(orderInfo.getOrder_sn());
 | 
	
		
			
				|  |  | -        if(entity !=null){
 | 
	
		
			
				|  |  | +            if (Dict.isSend.item_1.getItem().equalsIgnoreCase(entity.getIsCustomsSend()) && entity.getShipmentSuccTime() != null) {
 | 
	
		
			
				|  |  | +                WuliuVo wuliuVo = new WuliuVo();
 | 
	
		
			
				|  |  | +                wuliuVo.setAcceptStation("订单已出库");
 | 
	
		
			
				|  |  | +                wuliuVo.setAcceptTime(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(entity.getShipmentSuccTime()));
 | 
	
		
			
				|  |  | +                wuliuList.add(wuliuVo);
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +            if (Dict.isSend.item_1.getItem().equalsIgnoreCase(entity.getIsCustomsSend()) && entity.getShipmentStartTime() != null) {
 | 
	
		
			
				|  |  | +                WuliuVo wuliuVo = new WuliuVo();
 | 
	
		
			
				|  |  | +                wuliuVo.setAcceptStation("订单正在打包中");
 | 
	
		
			
				|  |  | +                wuliuVo.setAcceptTime(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(entity.getShipmentStartTime()));
 | 
	
		
			
				|  |  | +                wuliuList.add(wuliuVo);
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  |              if(Dict.isSend.item_1.getItem().equalsIgnoreCase(entity.getIsCustomsSend())){
 | 
	
		
			
				|  |  |                  WuliuVo wuliuVo = new WuliuVo();
 | 
	
		
			
				|  |  |                  wuliuVo.setAcceptStation("订单清关完成,等待仓库发货");
 |