代码备份

master
anthonywj 2 years ago
parent 1eb7afe25e
commit cfc9546ce4

@ -309,8 +309,10 @@ public class SpsSyncDataController {
if (StrUtil.isNotEmpty(upperServerHost)) { if (StrUtil.isNotEmpty(upperServerHost)) {
uri = upperServerHost + "/" + uri; uri = upperServerHost + "/" + uri;
} }
changeUri(uri); String uri2 = changeUri(uri);
JSONObject jsonObject = redirect(request, uri); logger.error("------------" + uri);
logger.error("------------" + uri2);
JSONObject jsonObject = redirect(request, uri2);
return jsonObject; return jsonObject;
} }

@ -77,7 +77,7 @@ public class SyncController {
String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service"); String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service");
if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) { if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) {
uri = uri.replace("orderApi/", ""); uri = uri.replace("orderApi/", "");
changeUri(uri); uri = changeUri(uri);
} }
String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip"); String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip");
if (StrUtil.isNotEmpty(upperServerHost)) { if (StrUtil.isNotEmpty(upperServerHost)) {
@ -95,7 +95,7 @@ public class SyncController {
String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service"); String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service");
if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) { if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) {
uri = uri.replace("busOrderApi/", ""); uri = uri.replace("busOrderApi/", "");
changeUri(uri); uri = changeUri(uri);
} }
String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip"); String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip");
@ -115,7 +115,7 @@ public class SyncController {
if (StrUtil.isNotEmpty(upperServerHost)) { if (StrUtil.isNotEmpty(upperServerHost)) {
uri = upperServerHost + "/" + uri; uri = upperServerHost + "/" + uri;
} }
changeUri(uri); uri = changeUri(uri);
JSONObject jsonObject = redirect(request, uri, ConstantStatus.SYNC_BUS_TYPE, BasicProcessStatus.NEW_ALL_BUS); JSONObject jsonObject = redirect(request, uri, ConstantStatus.SYNC_BUS_TYPE, BasicProcessStatus.NEW_ALL_BUS);
return jsonObject; return jsonObject;
} }
@ -129,7 +129,8 @@ public class SyncController {
if (StrUtil.isNotEmpty(upperServerHost)) { if (StrUtil.isNotEmpty(upperServerHost)) {
uri = upperServerHost + "/" + uri; uri = upperServerHost + "/" + uri;
} }
changeUri(uri); uri = changeUri(uri);
log.error(uri);
JSONObject jsonObject = redirect(request, uri, ConstantStatus.SYNC_BASIC_DATA, BasicProcessStatus.NEW_ALL_DATA); JSONObject jsonObject = redirect(request, uri, ConstantStatus.SYNC_BASIC_DATA, BasicProcessStatus.NEW_ALL_DATA);
return jsonObject; return jsonObject;
} }
@ -142,7 +143,7 @@ public class SyncController {
String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service"); String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service");
if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) { if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) {
uri = uri.replace("syncToSpms/", ""); uri = uri.replace("syncToSpms/", "");
changeUri(uri); uri = changeUri(uri);
} }
String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip"); String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip");
if (StrUtil.isNotEmpty(upperServerHost)) { if (StrUtil.isNotEmpty(upperServerHost)) {
@ -159,7 +160,7 @@ public class SyncController {
String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service"); String isTopService = systemParamConfigService.selectValueByParamKey("is_top_service");
if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) { if (StrUtil.isNotEmpty(isTopService) && isTopService.equals("1")) {
uri = uri.replace("directToSpms/", ""); uri = uri.replace("directToSpms/", "");
changeUri(uri); uri = changeUri(uri);
} }
String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip"); String upperServerHost = systemParamConfigService.selectValueByParamKey("upper_server_ip");
if (StrUtil.isNotEmpty(upperServerHost)) { if (StrUtil.isNotEmpty(upperServerHost)) {
@ -265,6 +266,7 @@ public class SyncController {
uri = uri.replace("SP_SYNC_SERVER/", ""); uri = uri.replace("SP_SYNC_SERVER/", "");
} }
} }
log.error("changeUri = " + uri);
return uri; return uri;
} }

@ -3,6 +3,8 @@ package com.glxp.sale.admin.service.auth.impl;
import com.glxp.sale.BaseApiAdminApplicationTest; import com.glxp.sale.BaseApiAdminApplicationTest;
import com.glxp.sale.admin.entity.auth.AuthPermissionRule; import com.glxp.sale.admin.entity.auth.AuthPermissionRule;
import com.glxp.sale.admin.service.auth.AuthPermissionRuleService; import com.glxp.sale.admin.service.auth.AuthPermissionRuleService;
import com.glxp.sale.admin.util.SnowflakeUtil;
import lombok.extern.slf4j.Slf4j;
import org.junit.Test; import org.junit.Test;
import javax.annotation.Resource; import javax.annotation.Resource;
@ -11,13 +13,18 @@ import java.util.List;
import static org.junit.Assert.*; import static org.junit.Assert.*;
@Slf4j
public class AuthPermissionRuleServiceImplTest extends BaseApiAdminApplicationTest { public class AuthPermissionRuleServiceImplTest extends BaseApiAdminApplicationTest {
@Resource @Resource
private AuthPermissionRuleService authPermissionRuleService; private AuthPermissionRuleService authPermissionRuleService;
@Resource
SnowflakeUtil snowflakeUtil;
@Test @Test
public void listByIdIn() { public void listByIdIn() {
log.error(snowflakeUtil.snowflakeId());
} }
@Test @Test

Loading…
Cancel
Save