Browse Source

接收推送的项目归集数据

tags/24080901
PoffyZhang 1 year ago
parent
commit
394dae06d2
9 changed files with 104 additions and 147 deletions
  1. +9
    -3
      pmapi/src/main/java/com/ningdatech/pmapi/gov/manage/GovProjectCollectionManage.java
  2. +0
    -1
      pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/utils/GenerateProjectCodeUtil.java
  3. +0
    -1
      pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectListReq.java
  4. +3
    -0
      pmapi/src/main/resources/application-dev.yml
  5. +3
    -0
      pmapi/src/main/resources/application-pre.yml
  6. +3
    -0
      pmapi/src/main/resources/application-prod.yml
  7. +26
    -47
      pmapi/src/test/resources/application-dev.yml
  8. +26
    -46
      pmapi/src/test/resources/application-pre.yml
  9. +34
    -49
      pmapi/src/test/resources/application-prod.yml

+ 9
- 3
pmapi/src/main/java/com/ningdatech/pmapi/gov/manage/GovProjectCollectionManage.java View File

@@ -13,7 +13,6 @@ import com.ningdatech.pmapi.gov.contants.BizProjectContant;
import com.ningdatech.pmapi.gov.convert.ProjectConvert;
import com.ningdatech.pmapi.gov.model.dto.*;
import com.ningdatech.pmapi.gov.model.entity.*;
import com.ningdatech.pmapi.gov.model.req.ProjectApplyReq;
import com.ningdatech.pmapi.gov.model.req.ProjectBaseInfoReq;
import com.ningdatech.pmapi.gov.model.req.ProjectPushReq;
import com.ningdatech.pmapi.gov.model.vo.*;
@@ -23,6 +22,7 @@ import com.ningdatech.pmapi.projectlib.model.req.ProjectListReq;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Component;
import org.springframework.web.client.RestTemplate;
@@ -62,6 +62,12 @@ public class GovProjectCollectionManage {

private final RestTemplate restTemplate;

@Value("${project.push-url}")
private String pushUrl;

@Value("${project.no-effective-url}")
private String noEffectiveUrl;

public List<GovProjectDictionaryVO> dictionary(String type) {

List<GovProjectDictionary> dictionaries = dictionaryService.list(Wrappers.lambdaQuery(GovProjectDictionary.class)
@@ -384,7 +390,7 @@ public class GovProjectCollectionManage {
* @param saveDTO
*/
private void pushProject(GovBizProjectSaveDTO saveDTO) {
String url = BizProjectContant.PUSH_URL;
String url = pushUrl;
ProjectPushReq req = ProjectConvert.convert(saveDTO);
try{
ResponseEntity<String> response = restTemplate.postForEntity(url, null, String.class, req);
@@ -399,7 +405,7 @@ public class GovProjectCollectionManage {
* @param baseinfo
*/
private void notEffectiveProject(GovBizProjectBaseinfoDTO baseinfo) {
String url = BizProjectContant.NOT_EFFECTIVE_URL;
String url = noEffectiveUrl;
baseinfo.setIsEffective(BizProjectContant.NOT_EFFECTIVE_CODE);
ProjectBaseInfoReq req = ProjectConvert.convertBase(baseinfo);
try{


+ 0
- 1
pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/utils/GenerateProjectCodeUtil.java View File

@@ -7,7 +7,6 @@ import com.ningdatech.pmapi.gov.model.dto.GovBizProjectApplyDTO;
import com.ningdatech.pmapi.gov.model.dto.GovBizProjectBaseinfoDTO;
import com.ningdatech.pmapi.gov.model.dto.GovBizProjectSaveDTO;
import com.ningdatech.pmapi.gov.model.entity.GovBizProjectApply;
import com.ningdatech.pmapi.gov.model.entity.GovBizProjectBaseinfo;
import com.ningdatech.pmapi.gov.service.IGovBizProjectApplyService;
import com.ningdatech.pmapi.projectdeclared.contants.ProjectCodeContant;
import com.ningdatech.pmapi.projectlib.model.dto.ProjectDTO;


+ 0
- 1
pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/req/ProjectListReq.java View File

@@ -2,7 +2,6 @@ package com.ningdatech.pmapi.projectlib.model.req;

import com.ningdatech.basic.model.PagePo;
import com.ningdatech.pmapi.common.enumeration.ExportOptionEnum;
import com.ningdatech.pmapi.projectlib.enumeration.ProjectLibFlagEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;


+ 3
- 0
pmapi/src/main/resources/application-dev.yml View File

@@ -230,6 +230,9 @@ irs:
request-token-url: https://interface.ls.local/a/api/requestTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
refresh-token-url: https://interface.ls.local/a/api/refreshTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
hostname: iZbp13nwyvib53j4j1p2xoZ
project:
push-url: http://120.26.44.207:38088/syn-data-task/open/api/v1/project-receive/save
no-effective-url: http://120.26.44.207:38088/syn-data-task/open/api/v1/project-receive/not-effective

login:
phone-verify-code:


+ 3
- 0
pmapi/src/main/resources/application-pre.yml View File

@@ -233,6 +233,9 @@ irs:
request-token-url: https://interface.ls.local/a/api/requestTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
refresh-token-url: https://interface.ls.local/a/api/refreshTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
hostname: iZ6mx01asxnsmennpzoxooZ
project:
push-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/save
no-effective-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/not-effective
login:
phone-verify-code:
skip: true


+ 3
- 0
pmapi/src/main/resources/application-prod.yml View File

@@ -233,6 +233,9 @@ irs:
request-token-url: https://interface.ls.local/a/api/requestTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
refresh-token-url: https://interface.ls.local/a/api/refreshTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
hostname: iZ6mx01gyeodd80imxd2gbZ
project:
push-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/save
no-effective-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/not-effective
login:
phone-verify-code:
skip: true


+ 26
- 47
pmapi/src/test/resources/application-dev.yml View File

@@ -41,53 +41,29 @@ spring:
hibernate:
ddl-auto: update
datasource:
type: com.alibaba.druid.pool.DruidDataSource
type: com.zaxxer.hikari.HikariDataSource
driverClassName: com.kingbase8.Driver
url: jdbc:kingbase8://120.26.44.207:54321/nd_project_management?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8
username: SYSTEM
password: Ndkj1234
# 数据源
druid:
url: jdbc:kingbase8://120.26.44.207:54321/nd_project_management?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8
username: SYSTEM
password: Ndkj1234
# 初始连接数
initialSize: 5
# 最小连接池数量
minIdle: 10
# 最大连接池数量
maxActive: 20
# 配置获取连接等待超时的时间
maxWait: 60000
# 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
timeBetweenEvictionRunsMillis: 60000
# 配置一个连接在池中最小生存的时间,单位是毫秒
minEvictableIdleTimeMillis: 300000
# 配置一个连接在池中最大生存的时间,单位是毫秒
maxEvictableIdleTimeMillis: 900000
# 配置检测连接是否有效
#mysql使用:SELECT 1 FROM DUAL
validationQuery: SELECT 1
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
webStatFilter:
enabled: true
statViewServlet:
enabled: true
# 设置白名单,不填则允许所有访问
allow:
url-pattern: /druid/*
# 控制台管理用户名和密码
login-username: admin
login-password: admin
filter:
stat:
enabled: true
# 慢SQL记录
log-slow-sql: true
slow-sql-millis: 1000
merge-sql: true
wall:
config:
multi-statement-allow: true
hikari:
# 是客户端等待连接池连接的最大毫秒数
connection-timeout: 30000
# 是允许连接在连接池中空闲的最长时间
minimum-idle: 5
# 配置最大池大小
maximum-pool-size: 20
# 是允许连接在连接池中空闲的最长时间(以毫秒为单位)
idle-timeout: 60000
# 池中连接关闭后的最长生命周期(以毫秒为单位)
max-lifetime: 600000
# 配置从池返回的连接的默认自动提交行为。默认值为true。
auto-commit: true
# 开启连接监测泄露
leak-detection-threshold: 5000
# 测试连接数据库
connection-test-query: SELECT 1
#设置上传 单个文件的大小
servlet:
multipart:
@@ -182,7 +158,7 @@ organization:
- GO_ff70e47bae684fdba0d64f4acab85661

yxt:
# wsdl-url: http://115.239.137.23:9501/ws/v1?wsdl
# wsdl-url: http://115.239.137.23:9501/ws/v1?wsdl
wsdl-url: classpath:/wsdl.xml
#账号
user-code: hzndkj
@@ -194,7 +170,7 @@ yxt:

#省局联审 请求信息
provincial:
# host: http://zj.ningdatech.com/prometheus-zhejiang_foreign
# host: http://zj.ningdatech.com/prometheus-zhejiang_foreign
host: http://223.4.72.75/prometheus-zhejiang_foreign
pushUrl: /api/v1/foreign/importantPro
detailUrl: /api/v1/foreign/importantProView
@@ -254,6 +230,9 @@ irs:
request-token-url: https://interface.ls.local/a/api/requestTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
refresh-token-url: https://interface.ls.local/a/api/refreshTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
hostname: iZbp13nwyvib53j4j1p2xoZ
project:
push-url: http://120.26.44.207:38088/syn-data-task/open/api/v1/project-receive/save
no-effective-url: http://120.26.44.207:38088/syn-data-task/open/api/v1/project-receive/not-effective

login:
phone-verify-code:


+ 26
- 46
pmapi/src/test/resources/application-pre.yml View File

@@ -40,53 +40,29 @@ spring:
hibernate:
ddl-auto: update
datasource:
type: com.alibaba.druid.pool.DruidDataSource
type: com.zaxxer.hikari.HikariDataSource
driverClassName: com.kingbase8.Driver
url: jdbc:kingbase8://10.53.168.41:54321/nd_project_management?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&nullCatalogMeansCurrent=true
username: SYSTEM
password: Ndkj1234
# 数据源
druid:
url: jdbc:kingbase8://10.53.168.41:54321/nd_project_management?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&nullCatalogMeansCurrent=true
username: SYSTEM
password: Ndkj1234
# 初始连接数
initialSize: 5
# 最小连接池数量
minIdle: 10
# 最大连接池数量
maxActive: 20
# 配置获取连接等待超时的时间
maxWait: 60000
# 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
timeBetweenEvictionRunsMillis: 60000
# 配置一个连接在池中最小生存的时间,单位是毫秒
minEvictableIdleTimeMillis: 300000
# 配置一个连接在池中最大生存的时间,单位是毫秒
maxEvictableIdleTimeMillis: 900000
# 配置检测连接是否有效
#mysql使用:SELECT 1 FROM DUAL
validationQuery: SELECT 1
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
webStatFilter:
enabled: true
statViewServlet:
enabled: true
# 设置白名单,不填则允许所有访问
allow:
url-pattern: /druid/*
# 控制台管理用户名和密码
login-username: admin
login-password: admin
filter:
stat:
enabled: true
# 慢SQL记录
log-slow-sql: true
slow-sql-millis: 1000
merge-sql: true
wall:
config:
multi-statement-allow: true
hikari:
# 是客户端等待连接池连接的最大毫秒数
connection-timeout: 30000
# 是允许连接在连接池中空闲的最长时间
minimum-idle: 10
# 配置最大池大小
maximum-pool-size: 20
# 是允许连接在连接池中空闲的最长时间(以毫秒为单位)
idle-timeout: 60000
# 池中连接关闭后的最长生命周期(以毫秒为单位)
max-lifetime: 600000
# 配置从池返回的连接的默认自动提交行为。默认值为true。
auto-commit: true
# 开启连接监测泄露
leak-detection-threshold: 5000
# 测试连接数据库
connection-test-query: SELECT 1
#设置上传 单个文件的大小
servlet:
multipart:
@@ -145,7 +121,7 @@ flowable:
async-executor-activate: true
#关闭一些不需要的功能服务
rest-api-enabled: false
# database-schema-update: false
# database-schema-update: false
idm:
enabled: false
common:
@@ -257,6 +233,10 @@ irs:
request-token-url: https://interface.ls.local/a/api/requestTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
refresh-token-url: https://interface.ls.local/a/api/refreshTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
hostname: iZ6mx01asxnsmennpzoxooZ
project:
push-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/save
no-effective-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/not-effective
login:
phone-verify-code:
skip: true
url: http://60.188.225.145:8080/login

+ 34
- 49
pmapi/src/test/resources/application-prod.yml View File

@@ -13,9 +13,9 @@ spring:
namespace: "spring:session"
redis:
timeout: 5000
host: 47.98.125.47
port: 26379
database: 4
host: localhost
port: 6379
database: 0
password: Ndkj1234
jedis:
pool:
@@ -40,53 +40,29 @@ spring:
hibernate:
ddl-auto: update
datasource:
type: com.alibaba.druid.pool.DruidDataSource
type: com.zaxxer.hikari.HikariDataSource
driverClassName: com.kingbase8.Driver
url: jdbc:kingbase8://10.53.172.221:54321/nd_project_management?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&nullCatalogMeansCurrent=true
username: SYSTEM
password: Ndkj1234
# 数据源
druid:
url: jdbc:kingbase8://10.53.172.221:54321/nd_project_management?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&nullCatalogMeansCurrent=true
username: SYSTEM
password: Ndkj1234
# 初始连接数
initialSize: 5
# 最小连接池数量
minIdle: 10
# 最大连接池数量
maxActive: 20
# 配置获取连接等待超时的时间
maxWait: 60000
# 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
timeBetweenEvictionRunsMillis: 60000
# 配置一个连接在池中最小生存的时间,单位是毫秒
minEvictableIdleTimeMillis: 300000
# 配置一个连接在池中最大生存的时间,单位是毫秒
maxEvictableIdleTimeMillis: 900000
# 配置检测连接是否有效
#mysql使用:SELECT 1 FROM DUAL
validationQuery: SELECT 1
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
webStatFilter:
enabled: true
statViewServlet:
enabled: true
# 设置白名单,不填则允许所有访问
allow:
url-pattern: /druid/*
# 控制台管理用户名和密码
login-username: admin
login-password: admin
filter:
stat:
enabled: true
# 慢SQL记录
log-slow-sql: true
slow-sql-millis: 1000
merge-sql: true
wall:
config:
multi-statement-allow: true
hikari:
# 是客户端等待连接池连接的最大毫秒数
connection-timeout: 30000
# 是允许连接在连接池中空闲的最长时间
minimum-idle: 10
# 配置最大池大小
maximum-pool-size: 20
# 是允许连接在连接池中空闲的最长时间(以毫秒为单位)
idle-timeout: 60000
# 池中连接关闭后的最长生命周期(以毫秒为单位)
max-lifetime: 600000
# 配置从池返回的连接的默认自动提交行为。默认值为true。
auto-commit: true
# 开启连接监测泄露
leak-detection-threshold: 5000
# 测试连接数据库
connection-test-query: SELECT 1
#设置上传 单个文件的大小
servlet:
multipart:
@@ -145,7 +121,7 @@ flowable:
async-executor-activate: true
#关闭一些不需要的功能服务
rest-api-enabled: false
# database-schema-update: false
# database-schema-update: false
idm:
enabled: false
common:
@@ -209,6 +185,11 @@ provincial:
#天印服务器接口信息
irs:
is-search-app: true
digital-resource-indicators:
url: https://interface.zjzwfw.gov.cn/gateway/api/proxy/001003001029/dataSharing/99E2bic31KdXzaa7.htm
interfaceName: 99E2bic31KdXzaa7
app-key: A331101453557202109017383
app-secret: 496f0f2a19994f76b4fd9dae087366c7
seal-platform:
project-id: 330001110
project-secret: 70e512d40c8f440484db4acab181570a
@@ -252,6 +233,10 @@ irs:
request-token-url: https://interface.ls.local/a/api/requestTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
refresh-token-url: https://interface.ls.local/a/api/refreshTokenKey?appKey={appKey}&requestTime={requestTime}&sign={sign}
hostname: iZ6mx01gyeodd80imxd2gbZ
project:
push-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/save
no-effective-url: http://10.53.168.41:38088/syn-data-task/open/api/v1/project-receive/not-effective
login:
phone-verify-code:
skip: true
url: http://60.188.225.145/login

Loading…
Cancel
Save