Kaynağa Gözat

用户管理中心添加对接高速,航道业务平台

tags/v2.4.1
xiaoying 1 yıl önce
ebeveyn
işleme
5204b7ba49
6 değiştirilmiş dosya ile 41 ekleme ve 21 silme
  1. +15
    -3
      tuoheng_oidc_admin/src/main/java/com/tuoheng/constant/FreeWayConstant.java
  2. +2
    -2
      tuoheng_oidc_admin/src/main/java/com/tuoheng/constant/HhzUrlConstant.java
  3. +4
    -0
      tuoheng_oidc_admin/src/main/java/com/tuoheng/constant/WaterWayConstant.java
  4. +20
    -16
      tuoheng_oidc_admin/src/main/java/com/tuoheng/service/impl/ClientUserServiceImpl.java
  5. BIN
      tuoheng_oidc_admin/target/classes/com/tuoheng/constant/HhzUrlConstant.class
  6. BIN
      tuoheng_oidc_admin/target/classes/com/tuoheng/service/impl/ClientUserServiceImpl.class

+ 15
- 3
tuoheng_oidc_admin/src/main/java/com/tuoheng/constant/FreeWayConstant.java Dosyayı Görüntüle

@@ -10,15 +10,27 @@ public class FreeWayConstant {
/**
* pc端
*/
public static final String FREEWAY_CLIENT_ADMIN = "tuoheng-waterway-admin";
public static final String FREEWAY_CLIENT_ADMIN = "tuoheng-freeway-admin";
/**
* web端
*/
public static final String FREEWAY_CLIENT_MP = "tuoheng-waterway-mp";

public static final String FREEWAY_CLIENT_MP = "tuoheng-freeway-mp";

public static final String FREEWAY_CLIENT="tuoheng-freeway";


public static final String FREEWAY_NAME="高速业务平台";

/**
* 创建租户
*/
public static final String CREATE_TENANT = "/oidc/callback/tenant/create";
/**
* 更新租户
*/
public static final String UPDATE_TENANT = "/oidc/callback/tenant/edit";
/**
* 逻辑删除租户
*/
public static final String DELETE_TENANT = "/oidc/callback/tenant/deleted";
}

+ 2
- 2
tuoheng_oidc_admin/src/main/java/com/tuoheng/constant/HhzUrlConstant.java Dosyayı Görüntüle

@@ -11,9 +11,9 @@ public class HhzUrlConstant {
/**
* 河湖长-pc端
*/
public static final String HHZ_CLIENT_ADMIN = "tuoheng-waterway-admin";
public static final String HHZ_CLIENT_ADMIN = "tuoheng-hhz-admin";

public static final String HHZ_CLIENT_MP = "tuoheng-waterway-mp";
public static final String HHZ_CLIENT_MP = "tuoheng-hhz-mp";




+ 4
- 0
tuoheng_oidc_admin/src/main/java/com/tuoheng/constant/WaterWayConstant.java Dosyayı Görüntüle

@@ -30,4 +30,8 @@ public class WaterWayConstant {
* 更新租户
*/
public static final String UPDATE_TENANT = "/oidc/callback/tenant/edit";
/**
* 逻辑删除租户
*/
public static final String DELETE_TENANT = "/oidc/callback/tenant/deleted";
}

+ 20
- 16
tuoheng_oidc_admin/src/main/java/com/tuoheng/service/impl/ClientUserServiceImpl.java Dosyayı Görüntüle

@@ -500,9 +500,11 @@ public class ClientUserServiceImpl implements ClientUserSevice {
case AirportConstant.AIRPORT_CLIENT:
url = url + AirportConstant.CREATE_TENANT;
break;
//case AirportConstant.AIRPORT_CLIENT:
// url = url + AirportConstant.CREATE_TENANT;
// break;
//高速
case FreeWayConstant.FREEWAY_CLIENT:
url = url + FreeWayConstant.CREATE_TENANT;
dto.setClientId(FreeWayConstant.FREEWAY_CLIENT_ADMIN + CommonConstant.COMMA + FreeWayConstant.FREEWAY_CLIENT_MP);
break;
//航道
case WaterWayConstant.WATERWAY_CLIENT:
url = url + WaterWayConstant.CREATE_TENANT;
@@ -525,7 +527,7 @@ public class ClientUserServiceImpl implements ClientUserSevice {
}
if (response.getBody().getCode() != JsonResult.SUCCESS) {
log.error("业务平台新增租户响应失败" + response.getBody());
return JsonResult.error(response.getBody().getMsg());
throw new ServiceException(HttpStatus.BAD_REQUEST.value(), response.getBody().getMsg());
}
return JsonResult.success();
}
@@ -556,21 +558,23 @@ public class ClientUserServiceImpl implements ClientUserSevice {
//河湖长
case HhzUrlConstant.HHZ_CLIENT:
url = url + HhzUrlConstant.UPDATE_TENANT;
dto.setClientId(HhzUrlConstant.HHZ_CLIENT_ADMIN);
break;
//机场
case AirportConstant.AIRPORT_CLIENT:
url = url + AirportConstant.EDIT_TENANT;
break;
//case AirportConstant.AIRPORT_CLIENT:
// url = url + AirportConstant.CREATE_TENANT;
// break;
case FreeWayConstant.FREEWAY_CLIENT:
url = url + FreeWayConstant.UPDATE_TENANT;
dto.setClientId(FreeWayConstant.FREEWAY_CLIENT_ADMIN + CommonConstant.COMMA + FreeWayConstant.FREEWAY_CLIENT_MP);
break;
case WaterWayConstant.WATERWAY_CLIENT:
url = url + WaterWayConstant.UPDATE_TENANT;
dto.setClientId(WaterWayConstant.WATERWAY_CLIENT_ADMIN + CommonConstant.COMMA + WaterWayConstant.WATERWAY_CLIENT_MP);
break;
default:
break;
}
log.info("请求url:{}", url);
ResponseEntity<JsonResult> response;
try {
log.info("请求url:{}", url);
@@ -584,7 +588,7 @@ public class ClientUserServiceImpl implements ClientUserSevice {
}
if (response.getBody().getCode() != JsonResult.SUCCESS) {
log.error("业务平台更新租户响应失败" + response.getBody());
return JsonResult.error(response.getBody().getMsg());
throw new ServiceException(HttpStatus.BAD_REQUEST.value(), response.getBody().getMsg());
}
return JsonResult.success();
}
@@ -620,12 +624,12 @@ public class ClientUserServiceImpl implements ClientUserSevice {
case AirportConstant.AIRPORT_CLIENT:
url = url + AirportConstant.DELETE_TENANT;
break;
//case AirportConstant.AIRPORT_CLIENT:
// url = url + AirportConstant.CREATE_TENANT;
// break;
//case AirportConstant.AIRPORT_CLIENT:
// url = url + AirportConstant.CREATE_TENANT;
// break;
case FreeWayConstant.FREEWAY_CLIENT:
url = url + FreeWayConstant.DELETE_TENANT;
break;
case WaterWayConstant.WATERWAY_CLIENT:
url = url + WaterWayConstant.DELETE_TENANT;
break;
default:
break;
}
@@ -642,7 +646,7 @@ public class ClientUserServiceImpl implements ClientUserSevice {
}
if (response.getBody().getCode() != JsonResult.SUCCESS) {
log.error("业务平台删除租户响应失败" + response.getBody());
return JsonResult.error(response.getBody().getMsg());
throw new ServiceException(HttpStatus.BAD_REQUEST.value(), response.getBody().getMsg());
}
return JsonResult.success();
}

BIN
tuoheng_oidc_admin/target/classes/com/tuoheng/constant/HhzUrlConstant.class Dosyayı Görüntüle


BIN
tuoheng_oidc_admin/target/classes/com/tuoheng/service/impl/ClientUserServiceImpl.class Dosyayı Görüntüle


Yükleniyor…
İptal
Kaydet