Browse Source

Merge remote-tracking branch 'remotes/origin/dev_tduck_mix' into dev_question_naire

dev_shibei_match
jianjun 4 years ago
parent
commit
53a48242eb
  1. 5
      epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/dto/result/CustomerStaffInfoCacheResult.java
  2. 5
      epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/common/bean/CustomerStaffInfoCache.java
  3. 10
      epmet-gateway/pom.xml
  4. 4
      epmet-gateway/src/main/java/com/epmet/filter/CpAuthGatewayFilterFactory.java
  5. 11
      epmet-gateway/src/main/resources/bootstrap.yml
  6. 5
      epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/epmetuser/result/CustomerStaffResultDTO.java
  7. 1
      epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java

5
epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/dto/result/CustomerStaffInfoCacheResult.java

@ -22,6 +22,11 @@ public class CustomerStaffInfoCacheResult implements Serializable {
*/
private String agencyId;
/**
* 工作人员所属组织ID的pids
*/
private String agencyPIds;
/**
* 工作人员所属组织名称
*/

5
epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/common/bean/CustomerStaffInfoCache.java

@ -22,6 +22,11 @@ public class CustomerStaffInfoCache implements Serializable {
*/
private String agencyId;
/**
* 工作人员所属组织ID的pids
*/
private String agencyPIds;
/**
* 工作人员所属组织名称
*/

10
epmet-gateway/pom.xml

@ -233,6 +233,9 @@
<!--宣传服务-->
<gateway.routes.epmet-openapi-adv-server.url>lb://epmet-openapi-adv-server</gateway.routes.epmet-openapi-adv-server.url>
<!--<gateway.routes.epmet-ext-server.url>lb://127.0.0.1:8115</gateway.routes.epmet-ext-server.url>-->
<!--问卷服务-->
<gateway.routes.tduck-api.url>lb://tduck-api</gateway.routes.tduck-api.url>
<!--<gateway.routes.tduck-api.url>http://localhost:8116</gateway.routes.tduck-api.url>-->
<!--钉钉 机器人地址-->
<dingTalk.robot.webHook>https://oapi.dingtalk.com/robot/send?access_token=e894e5690f9d6a527722974c71548ff6c0fe29bd956589a09e21b16442a35ed4</dingTalk.robot.webHook>
<dingTalk.robot.secret>SECfcc020bdc83bb17a2c00f39977b1fbc409ef4188c7beaea11c5caa90eeaf87fd</dingTalk.robot.secret>
@ -364,6 +367,9 @@
<!--宣传服务-->
<gateway.routes.epmet-openapi-adv-server.url>lb://epmet-openapi-adv-server</gateway.routes.epmet-openapi-adv-server.url>
<!--<gateway.routes.epmet-openapi-adv-server.url>http://localhost:8115</gateway.routes.epmet-openapi-adv-server.url>-->
<!--问卷服务-->
<gateway.routes.tduck-api.url>lb://tduck-api</gateway.routes.tduck-api.url>
<!--<gateway.routes.tduck-api.url>http://localhost:8116</gateway.routes.tduck-api.url>-->
<!--钉钉 机器人地址-->
<dingTalk.robot.webHook>https://oapi.dingtalk.com/robot/send?access_token=e894e5690f9d6a527722974c71548ff6c0fe29bd956589a09e21b16442a35ed4</dingTalk.robot.webHook>
<dingTalk.robot.secret>SECfcc020bdc83bb17a2c00f39977b1fbc409ef4188c7beaea11c5caa90eeaf87fd</dingTalk.robot.secret>
@ -461,6 +467,8 @@
<gateway.routes.epmet-ext-server.url>lb://epmet-ext-server</gateway.routes.epmet-ext-server.url>
<!-- 35、多数据源服务 -->
<gateway.routes.data-aggregator-server.url>lb://data-aggregator-server</gateway.routes.data-aggregator-server.url>
<!--问卷服务-->
<gateway.routes.tduck-api.url>lb://tduck-api</gateway.routes.tduck-api.url>
<!--宣传服务-->
<gateway.routes.epmet-openapi-adv-server.url>lb://epmet-openapi-adv-server</gateway.routes.epmet-openapi-adv-server.url>
@ -561,6 +569,8 @@
<!--宣传服务-->
<gateway.routes.epmet-openapi-adv-server.url>lb://epmet-openapi-adv-server</gateway.routes.epmet-openapi-adv-server.url>
<!--问卷服务-->
<gateway.routes.tduck-api.url>lb://tduck-api</gateway.routes.tduck-api.url>
<!--生产钉钉 机器人地址-->
<dingTalk.robot.webHook>https://oapi.dingtalk.com/robot/send?access_token=a5f66c3374b1642fe2142dbf56d5997e280172d4e8f2b546c9423a68c82ece6c</dingTalk.robot.webHook>
<dingTalk.robot.secret>SEC95f4f40b533ad379ea6a6d1af6dd37029383cfe1b7cd96dfac2678be2c1c3ed1</dingTalk.robot.secret>

4
epmet-gateway/src/main/java/com/epmet/filter/CpAuthGatewayFilterFactory.java

@ -105,10 +105,10 @@ public class CpAuthGatewayFilterFactory extends AbstractGatewayFilterFactory<CpA
break;
}
} catch (RenException e) {
logger.error("CpAuthGatewayFilterFactory认证出错,错误信息:{}", ExceptionUtils.getErrorStackTrace(e));
logger.error("CpAuthGatewayFilterFactory认证出错RenException,错误信息:{}", ExceptionUtils.getErrorStackTrace(e));
return response(exchange, new Result<>().error(e.getCode(), e.getMessage()));
} catch (Exception e) {
logger.error("CpAuthGatewayFilterFactory认证出错,错误信息:{}", ExceptionUtils.getErrorStackTrace(e));
logger.error("CpAuthGatewayFilterFactory认证出错Exception,错误信息:{}", ExceptionUtils.getErrorStackTrace(e));
return response(exchange, new Result<>().error(e.getMessage()));
}

11
epmet-gateway/src/main/resources/bootstrap.yml

@ -336,12 +336,20 @@ spring:
# 宣传服务
- id: epmet-openapi-adv-server
uri: @gateway.routes.epmet-openapi-adv-server.url@
order: 35
order: 36
predicates:
- Path=${server.servlet.context-path}/adv/**
filters:
- StripPrefix=1
- CpAuth=true
- id: tduck-api
uri: @gateway.routes.tduck-api.url@
order: 37
predicates:
- Path=${server.servlet.context-path}/tduck-api/**
filters:
- StripPrefix=1
- CpAuth=true
nacos:
discovery:
server-addr: @nacos.server-addr@
@ -472,6 +480,7 @@ epmet:
- /epmetuser/customerstaff/customerlist
- /gov/project/project/platformcallback
- /oper/customize/customerstartpage/homestartpage
- /tduck-api/**
# 外部应用认证,使用AccessToken等头进行认证
externalOpenUrls:

5
epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/epmetuser/result/CustomerStaffResultDTO.java

@ -21,6 +21,11 @@ public class CustomerStaffResultDTO implements Serializable {
*/
private String agencyId;
/**
* 工作人员所属组织ID的pids
*/
private String agencyPIds;
/**
* 工作人员所属组织名称
*/

1
epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java

@ -600,6 +600,7 @@ public class EpmetUserServiceImpl implements EpmetUserService {
}
result.setAgencyId(agencyDTO.getId());
result.setAgencyName(agencyDTO.getOrganizationName());
result.setAgencyPIds(agencyDTO.getPids());
StaffOrgRelationResultDTO fromOrgTypeDto = govOrgService.getStaffFromOrgType(staffId);
String fromOrgType = OrgTypeEnum.AGENCY.getCode();
if (fromOrgTypeDto != null){

Loading…
Cancel
Save