diff --git a/api-admin/src/main/java/com/glxp/sale/admin/idc/service/impl/IdcServiceImpl.java b/api-admin/src/main/java/com/glxp/sale/admin/idc/service/impl/IdcServiceImpl.java index 166d8a3..4cf58dd 100644 --- a/api-admin/src/main/java/com/glxp/sale/admin/idc/service/impl/IdcServiceImpl.java +++ b/api-admin/src/main/java/com/glxp/sale/admin/idc/service/impl/IdcServiceImpl.java @@ -157,14 +157,14 @@ public class IdcServiceImpl implements IdcService { if(direction.equals("I")) { tNames = SPMS_TO_UDI_TABLES; - } else { + } else if (direction.equals("U")) { tNames = UDI_TO_SPMS_TABLES; } /*为顶级或末级,以及下游或上游连通,可执行*/ Boolean isLastLevel = isLastLevel(direction); Boolean isRelay = isRelay(direction); logger.info("-----数据传输任务开始----"+direction+"\n"); - logger.info("-----是否顶级或末级服务:"+isLastLevel+",是否转发数据:"+isRelay+"----\n"); + logger.info("-----是否需要上传或下发数据:"+isLastLevel+",是否已配置接收地址:"+isRelay+"----\n"); if(isLastLevel&&isRelay) { for(String t:tNames) { uploadData(t); @@ -602,8 +602,8 @@ public class IdcServiceImpl implements IdcService { /*获取转发服务地址,当前值允许单向,只使用参数upper_server_ip*/ private String getNextHost(String direction) { SystemParamConfigEntity systemParamConfigEntity = - direction.equals("U") ? getSystemParamConfig("upper_server_host","自助平台数据接收服务地址" , "","") : - direction.equals("I") ? getSystemParamConfig("lower_server_host","UDI系统数据接收服务地址" , "","") : null; + direction.equals("U") ? getSystemParamConfig("upper_server_host","自助平台数据接收服务地址" , "","接收由UDI系统上传的数据") : + direction.equals("I") ? getSystemParamConfig("lower_server_host","UDI系统数据接收服务地址" , "","接收由自助平台下发的数据") : null; String host = systemParamConfigEntity!=null ? systemParamConfigEntity.getParamValue() : ""; host = !StringUtils.isEmpty(host)&&host.substring(host.length() -1).equals("/") ? host.substring(0,host.length() -1) : host; return host; @@ -615,7 +615,7 @@ public class IdcServiceImpl implements IdcService { } /*检查当前系统为自助平台(下发)还是UDI系统(上传),返回传输方向,如果都未设置,默认返回下发*/ private String getDirection() { - SystemParamConfigEntity systemParamConfigEntity = getSystemParamConfig("sync_system_type","系统类型" , "IDC","UDI(UDI管理系统),SPS(自助平台),IDC(中继服务)"); + SystemParamConfigEntity systemParamConfigEntity = getSystemParamConfig("sync_system_type","系统类型" , "IDC","UDI(UDI管理系统,需要往自助平台上传数据),SPS(自助平台,需要往UDI系统下发数据),IDC(中继服务,只接收,转发或暂存数据供下一级服务拉取数据)"); return systemParamConfigEntity.getParamValue().equals("UDI") ? "U" : systemParamConfigEntity.getParamValue().equals("SPS") ? "I" : "N"; }