Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
e32836e9
Commit
e32836e9
authored
Mar 02, 2023
by
zhangyingbin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tzs注册、access和openapi国产数据库适配
parent
4804f134
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
248 additions
and
35 deletions
+248
-35
pom.xml
amos-boot-data/amos-boot-data-accessapi/pom.xml
+26
-0
TaBusinessServiceImpl.java
.../amos/api/openapi/face/service/TaBusinessServiceImpl.java
+1
-1
application-dev1.properties
...-accessapi/src/main/resources/application-dev1.properties
+51
-0
application.properties
...-data-accessapi/src/main/resources/application.properties
+1
-1
logback-dev1.xml
...s-boot-data-accessapi/src/main/resources/logback-dev1.xml
+53
-0
BaseUnitLicenceMapper.xml
...ssapi/src/main/resources/mapper/BaseUnitLicenceMapper.xml
+1
-1
pom.xml
amos-boot-data/amos-boot-data-openapi/pom.xml
+25
-0
application-dev.properties
...ata-openapi/src/main/resources/application-dev.properties
+12
-12
DynamicFormInstanceMapper.xml
...i/src/main/resources/mapper/DynamicFormInstanceMapper.xml
+1
-1
RegUnitIcDto.java
...eejoin/amos/boot/module/tzs/flc/api/dto/RegUnitIcDto.java
+11
-0
UnitInfoController.java
...oot/module/tzs/flc/biz/controller/UnitInfoController.java
+17
-0
RegUnitInfoServiceImpl.java
...dule/tzs/flc/biz/service/impl/RegUnitInfoServiceImpl.java
+34
-18
logback-dev.xml
...os-boot-module-tzs-biz/src/main/resources/logback-dev.xml
+7
-0
logback-dev2.xml
...s-boot-module-tzs-biz/src/main/resources/logback-dev2.xml
+8
-1
No files found.
amos-boot-data/amos-boot-data-accessapi/pom.xml
View file @
e32836e9
...
@@ -141,6 +141,32 @@
...
@@ -141,6 +141,32 @@
<artifactId>
license-sdk
</artifactId>
<artifactId>
license-sdk
</artifactId>
<version>
1.0.0
</version>
<version>
1.0.0
</version>
</dependency>
</dependency>
<!-- druid -->
<dependency>
<groupId>
com.alibaba
</groupId>
<artifactId>
druid-spring-boot-starter
</artifactId>
<version>
1.1.10
</version>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-jdbc
</artifactId>
</dependency>
<!-- Vastbase G100 -->
<dependency>
<groupId>
cn.com.vastdata
</groupId>
<artifactId>
vastbase
</artifactId>
<version>
1.0.0.1
</version>
</dependency>
<!-- LOG4J -->
<dependency>
<groupId>
log4j
</groupId>
<artifactId>
log4j
</artifactId>
<version>
1.2.16
</version>
<scope>
compile
</scope>
</dependency>
</dependencies>
</dependencies>
<build>
<build>
<plugins>
<plugins>
...
...
amos-boot-data/amos-boot-data-accessapi/src/main/java/com/yeejoin/amos/api/openapi/face/service/TaBusinessServiceImpl.java
View file @
e32836e9
...
@@ -112,7 +112,7 @@ public class TaBusinessServiceImpl extends BaseService<TaAccessConfigModel, TaAc
...
@@ -112,7 +112,7 @@ public class TaBusinessServiceImpl extends BaseService<TaAccessConfigModel, TaAc
//法定代表人姓名
//法定代表人姓名
result
.
put
(
"legalPeople"
,
data
.
get
(
"lerep"
));
result
.
put
(
"legalPeople"
,
data
.
get
(
"lerep"
));
//行业小类编码
//行业小类编码
result
.
put
(
""
,
data
.
get
(
"hydm"
));
result
.
put
(
"
industryCode
"
,
data
.
get
(
"hydm"
));
}
else
{
}
else
{
System
.
out
.
println
(
"失败:"
+
response
.
getErrorMsg
());
System
.
out
.
println
(
"失败:"
+
response
.
getErrorMsg
());
System
.
out
.
println
(
"失败:"
+
response
.
getErrorCode
());
System
.
out
.
println
(
"失败:"
+
response
.
getErrorCode
());
...
...
amos-boot-data/amos-boot-data-accessapi/src/main/resources/application-dev1.properties
0 → 100644
View file @
e32836e9
spring.application.name
=
AMOS-API-ACCESSAPI
server.servlet.context-path
=
/accessapi
server.port
=
11005
# jdbc_config
spring.datasource.driver-class-name
=
org.postgresql.Driver
spring.datasource.url
=
jdbc:postgresql://172.16.10.213:5432/per_tzs_amos_tzs_biz?currentSchema=per_tzs_amos_data_accessapi
spring.datasource.username
=
vbadmin
spring.datasource.password
=
Yeejoin@2023
spring.datasource.type
=
com.zaxxer.hikari.HikariDataSource
spring.datasource.hikari.minimum-idle
=
5
spring.datasource.hikari.maximum-pool-size
=
15
spring.datasource.hikari.auto-commit
=
true
spring.datasource.hikari.idle-timeout
=
30000
spring.datasource.hikari.pool-name
=
DatebookHikariCP
spring.datasource.hikari.max-lifetime
=
1800000
spring.datasource.hikari.connection-timeout
=
30000
spring.datasource.hikari.connection-test-query
=
SELECT 1
# REDIS (RedisProperties)
spring.redis.database
=
1
spring.redis.host
=
172.16.10.210
spring.redis.port
=
6379
spring.redis.password
=
yeejoin@2020
spring.redis.lettuce.pool.max-active
=
200
spring.redis.lettuce.pool.max-wait
=
-1
spring.redis.lettuce.pool.max-idle
=
10
spring.redis.lettuce.pool.min-idle
=
0
spring.redis.expire.time
=
300
#注册中心地址
eureka.client.service-url.defaultZone
=
http://172.16.10.210:10001/eureka/
eureka.instance.prefer-ip-address
=
true
management.endpoint.health.show-details
=
always
management.endpoints.web.exposure.include
=
*
eureka.instance.health-check-url
=
http://localhost:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.metadata-map.management.context-path
=
${server.servlet.context-path}/actuator
eureka.instance.status-page-url
=
http://localhost:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.metadata-map.management.api-docs
=
http://localhost:${server.port}${server.servlet.context-path}/swagger-ui.html
eureka.instance.ip-address
=
localhost
eureka.instance.instance-id
=
${eureka.instance.ip-address}:${server.port}
##emqx
emqx.clean-session
=
true
emqx.client-id
=
${spring.application.name}-${random.int[1024,65536]}
emqx.broker
=
tcp://172.16.10.210:1883
emqx.client-user-name
=
admin
emqx.client-password
=
public
##biz custem properties
biz.lxyd.lift.url
=
http://39.106.181.149:8088/elevatorapi
\ No newline at end of file
amos-boot-data/amos-boot-data-accessapi/src/main/resources/application.properties
View file @
e32836e9
spring.profiles.active
=
dev
spring.profiles.active
=
dev
1
server.compression.enabled
=
true
server.compression.enabled
=
true
spring.jackson.dateFormat
=
yyyy-MM-dd HH:mm:ss
spring.jackson.dateFormat
=
yyyy-MM-dd HH:mm:ss
...
...
amos-boot-data/amos-boot-data-accessapi/src/main/resources/logback-dev1.xml
0 → 100644
View file @
e32836e9
<?xml version="1.0" encoding="UTF-8"?>
<configuration
debug=
"false"
>
<!--定义日志文件的存储地址 勿在 LogBack 的配置中使用相对路径-->
<property
name=
"LOG_HOME"
value=
"/opt/log/qa"
/>
<!--格式化输出:%d表示日期,%thread表示线程名,%-5level:级别从左显示5个字符宽度%msg:日志消息,%n是换行符-->
<property
name=
"LOG_PATTERN"
value=
"%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %-50.50logger{50} - %msg [%file:%line] %n"
/>
<!-- 按照每天生成日志文件 -->
<appender
name=
"FILE"
class=
"ch.qos.logback.core.rolling.RollingFileAppender"
>
<rollingPolicy
class=
"ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"
>
<!--日志文件输出的文件名-->
<FileNamePattern>
${LOG_HOME}/tzs.log.%d{yyyy-MM-dd}.%i.log
</FileNamePattern>
<!--日志文件保留天数-->
<MaxHistory>
7
</MaxHistory>
<!--日志文件大小-->
<MaxFileSize>
10mb
</MaxFileSize>
</rollingPolicy>
<encoder
class=
"ch.qos.logback.classic.encoder.PatternLayoutEncoder"
>
<pattern>
${LOG_PATTERN}
</pattern>
</encoder>
</appender>
<!-- 控制台输出 -->
<appender
name=
"STDOUT"
class=
"ch.qos.logback.core.ConsoleAppender"
>
<encoder
class=
"ch.qos.logback.classic.encoder.PatternLayoutEncoder"
>
<pattern>
${LOG_PATTERN}
</pattern>
</encoder>
</appender>
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
<logger name="org.hibernate.SQL" level="DEBUG" />
<logger name="org.hibernate.engine.QueryParameters" level="DEBUG" />
<logger name="org.hibernate.engine.query.HQLQueryPlan" level="DEBUG" />
-->
<!--myibatis log configure-->
<logger
name=
"com.apache.ibatis"
level=
"INFO"
/>
<logger
name=
"org.mybatis"
level=
"INFO"
/>
<logger
name=
"java.sql.Connection"
level=
"INFO"
/>
<logger
name=
"java.sql.Statement"
level=
"INFO"
/>
<logger
name=
"java.sql.PreparedStatement"
level=
"INFO"
/>
<logger
name=
"org.springframework"
level=
"INFO"
/>
<logger
name=
"com.baomidou.mybatisplus"
level=
"INFO"
/>
<logger
name=
"org.apache.activemq"
level=
"INFO"
/>
<logger
name=
"org.typroject"
level=
"INFO"
/>
<logger
name=
"com.yeejoin"
level=
"INFO"
/>
<!-- 日志输出级别 -->
<root
level=
"DEBUG"
>
<appender-ref
ref=
"FILE"
/>
<appender-ref
ref=
"STDOUT"
/>
</root>
</configuration>
\ No newline at end of file
amos-boot-data/amos-boot-data-accessapi/src/main/resources/mapper/BaseUnitLicenceMapper.xml
View file @
e32836e9
...
@@ -2,6 +2,6 @@
...
@@ -2,6 +2,6 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.api.openapi.face.orm.dao.DataDictionaryMapper"
>
<mapper
namespace=
"com.yeejoin.amos.api.openapi.face.orm.dao.DataDictionaryMapper"
>
<select
id=
"getData"
resultType=
"java.lang.String"
>
<select
id=
"getData"
resultType=
"java.lang.String"
>
select
`name` FROM cb_data_dictionary WHERE code=#{code} and type="IndustryCode"
select
cb_data_dictionary.name FROM cb_data_dictionary WHERE code=#{code} and type='IndustryCode'
</select>
</select>
</mapper>
</mapper>
amos-boot-data/amos-boot-data-openapi/pom.xml
View file @
e32836e9
...
@@ -14,6 +14,31 @@
...
@@ -14,6 +14,31 @@
<dependencies>
<dependencies>
<!-- druid -->
<dependency>
<groupId>
com.alibaba
</groupId>
<artifactId>
druid-spring-boot-starter
</artifactId>
<version>
1.1.10
</version>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-jdbc
</artifactId>
</dependency>
<!-- Vastbase G100 -->
<dependency>
<groupId>
cn.com.vastdata
</groupId>
<artifactId>
vastbase
</artifactId>
<version>
1.0.0.1
</version>
</dependency>
<!-- LOG4J -->
<dependency>
<groupId>
log4j
</groupId>
<artifactId>
log4j
</artifactId>
<version>
1.2.16
</version>
<scope>
compile
</scope>
</dependency>
<dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-netflix-eureka-client
</artifactId>
<artifactId>
spring-cloud-starter-netflix-eureka-client
</artifactId>
...
...
amos-boot-data/amos-boot-data-openapi/src/main/resources/application-dev.properties
View file @
e32836e9
spring.application.name
=
AMOS-API-OPENAPI
spring.application.name
=
AMOS-API-OPENAPI
server.servlet.context-path
=
/openapi
server.servlet.context-path
=
/openapi
server.port
=
1100
4
server.port
=
1100
1
# jdbc_config
# jdbc_config
spring.datasource.
url
=
jdbc:mysql://172.16.10.90:53306/tzs_amos_openapi?allowMultiQueries=true&serverTimezone=GMT%2B8
\
spring.datasource.
driver-class-name
=
org.postgresql.Driver
&characterEncoding=utf8
spring.datasource.url
=
jdbc:postgresql://172.16.10.213:5432/per_tzs_amos_tzs_biz?currentSchema=per_tzs_amos_openapi_cyl
spring.datasource.username
=
root
spring.datasource.username
=
vbadmin
spring.datasource.password
=
Yeejoin@202
0
spring.datasource.password
=
Yeejoin@202
3
spring.datasource.driver-class-name
=
com.mysql.cj.jdbc.Driver
spring.datasource.type
=
com.zaxxer.hikari.HikariDataSource
spring.datasource.type
=
com.zaxxer.hikari.HikariDataSource
spring.datasource.hikari.minimum-idle
=
5
spring.datasource.hikari.minimum-idle
=
5
spring.datasource.hikari.maximum-pool-size
=
15
spring.datasource.hikari.maximum-pool-size
=
15
...
@@ -19,7 +19,7 @@ spring.datasource.hikari.connection-test-query=SELECT 1
...
@@ -19,7 +19,7 @@ spring.datasource.hikari.connection-test-query=SELECT 1
# REDIS (RedisProperties)
# REDIS (RedisProperties)
spring.redis.database
=
1
spring.redis.database
=
1
spring.redis.host
=
172.16.10.
9
0
spring.redis.host
=
172.16.10.
21
0
spring.redis.port
=
6379
spring.redis.port
=
6379
spring.redis.password
=
yeejoin@2020
spring.redis.password
=
yeejoin@2020
spring.redis.lettuce.pool.max-active
=
200
spring.redis.lettuce.pool.max-active
=
200
...
@@ -29,19 +29,19 @@ spring.redis.lettuce.pool.min-idle=0
...
@@ -29,19 +29,19 @@ spring.redis.lettuce.pool.min-idle=0
spring.redis.expire.time
=
300
spring.redis.expire.time
=
300
#注册中心地址
#注册中心地址
eureka.client.service-url.defaultZone
=
http://
172.16.3.99
:10001/eureka/
eureka.client.service-url.defaultZone
=
http://
admin:a1234560@172.16.10.210
:10001/eureka/
eureka.instance.prefer-ip-address
=
true
eureka.instance.prefer-ip-address
=
true
management.endpoint.health.show-details
=
always
management.endpoint.health.show-details
=
always
management.endpoints.web.exposure.include
=
*
management.endpoints.web.exposure.include
=
*
eureka.instance.health-check-url
=
http://
localhost
:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.health-check-url
=
http://
172.16.10.210
:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.metadata-map.management.context-path
=
${server.servlet.context-path}/actuator
eureka.instance.metadata-map.management.context-path
=
${server.servlet.context-path}/actuator
eureka.instance.status-page-url
=
http://
localhost
:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.status-page-url
=
http://
172.16.10.210
:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.metadata-map.management.api-docs
=
http://
localhost
:${server.port}${server.servlet.context-path}/swagger-ui.html
eureka.instance.metadata-map.management.api-docs
=
http://
172.16.10.210
:${server.port}${server.servlet.context-path}/swagger-ui.html
##emqx
##emqx
emqx.clean-session
=
true
emqx.clean-session
=
true
emqx.client-id
=
${spring.application.name}-${random.int[1024,65536]}
emqx.client-id
=
${spring.application.name}-${random.int[1024,65536]}
emqx.broker
=
tcp://
36.46.151.113
:1883
emqx.broker
=
tcp://
172.16.10.210
:1883
emqx.client-user-name
=
super
emqx.client-user-name
=
super
emqx.client-password
=
123456
emqx.client-password
=
123456
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/resources/mapper/DynamicFormInstanceMapper.xml
View file @
e32836e9
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
v.rec_user_id recUserId,
v.rec_user_id recUserId,
v.rec_date recDate,
v.rec_date recDate,
v.is_delete isDelete,
v.is_delete isDelete,
v.block
block
,
v.block
"block"
,
f.field_type fieldType
f.field_type fieldType
FROM cb_dynamic_form_instance v
FROM cb_dynamic_form_instance v
LEFT JOIN cb_dynamic_form_column f ON f.sequence_nbr = v.form_column_id
LEFT JOIN cb_dynamic_form_column f ON f.sequence_nbr = v.form_column_id
...
...
amos-boot-system-tzs/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/RegUnitIcDto.java
View file @
e32836e9
...
@@ -6,6 +6,8 @@ import io.swagger.annotations.ApiModelProperty;
...
@@ -6,6 +6,8 @@ import io.swagger.annotations.ApiModelProperty;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.EqualsAndHashCode
;
import
org.springframework.format.annotation.DateTimeFormat
;
import
java.util.Date
;
import
java.util.Date
;
/**
/**
...
@@ -47,4 +49,13 @@ public class RegUnitIcDto extends BaseDto {
...
@@ -47,4 +49,13 @@ public class RegUnitIcDto extends BaseDto {
@ApiModelProperty
(
value
=
"经营状态code"
)
@ApiModelProperty
(
value
=
"经营状态code"
)
private
String
businessStateCode
;
private
String
businessStateCode
;
private
String
area
;
private
String
stree
;
private
String
community
;
private
String
address
;
private
String
legalPerson
;
private
String
province
;
private
String
city
;
private
String
district
;
}
}
amos-boot-system-tzs/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/UnitInfoController.java
View file @
e32836e9
...
@@ -102,10 +102,27 @@ public class UnitInfoController extends BaseController {
...
@@ -102,10 +102,27 @@ public class UnitInfoController extends BaseController {
}
else
{
}
else
{
result
=
Systemctl
.
regionClient
.
querySubAgencyTree
(
parentId
).
getResult
();
result
=
Systemctl
.
regionClient
.
querySubAgencyTree
(
parentId
).
getResult
();
}
}
despace
(
result
);
return
ResponseHelper
.
buildResponse
(
result
);
return
ResponseHelper
.
buildResponse
(
result
);
}
}
/**
/**
* 去区域树中level多余空格
* @param result
*/
public
void
despace
(
Collection
<
RegionModel
>
result
){
Iterator
<
RegionModel
>
iterator
=
result
.
iterator
();
while
(
iterator
.
hasNext
())
{
RegionModel
regionModel
=
iterator
.
next
();
regionModel
.
setLevel
(
regionModel
.
getLevel
().
trim
());
regionModel
.
setLevelName
(
regionModel
.
getLevelName
().
trim
());
if
(!
ValidationUtil
.
isEmpty
(
regionModel
.
getChildren
()))
{
despace
(
regionModel
.
getChildren
());
}
}
}
/**
* 获取管辖单位树
* 获取管辖单位树
*
*
* @return
* @return
...
...
amos-boot-system-tzs/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/RegUnitInfoServiceImpl.java
View file @
e32836e9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
import
java.text.ParseException
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.Collection
;
import
java.util.Collection
;
import
java.util.Collections
;
import
java.util.Collections
;
import
java.util.Date
;
import
java.util.Date
;
...
@@ -13,7 +13,7 @@ import java.util.Map;
...
@@ -13,7 +13,7 @@ import java.util.Map;
import
java.util.Set
;
import
java.util.Set
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
import
com.yeejoin.amos.boot.
module.tzs.biz.utils.RedisUtil
;
import
com.yeejoin.amos.boot.
biz.common.utils.DateUtils
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.feign.AccessFeignService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.feign.AccessFeignService
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -21,7 +21,6 @@ import org.springframework.beans.factory.annotation.Value;
...
@@ -21,7 +21,6 @@ import org.springframework.beans.factory.annotation.Value;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.web.client.RestTemplate
;
import
org.springframework.web.client.RestTemplate
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
...
@@ -248,13 +247,6 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
...
@@ -248,13 +247,6 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
// }
// }
// 2.组织返回数据
// 2.组织返回数据
RegUnitInfoDto
regUnitInfoDto
=
new
RegUnitInfoDto
();
RegUnitInfoDto
regUnitInfoDto
=
new
RegUnitInfoDto
();
if
(
USE_UNIT_TYPE_CODE
.
equals
(
unitType
)
||
PRODUCT_UNIT_TYPE_CODE
.
equals
(
unitType
)
||
FILLING_UNIT_TYPE_CODE
.
equals
(
unitType
))
{
// 本地库有的化 就不去其他系统查询
RegUnitIc
regUnitIc
=
regUnitIcService
.
getOne
(
new
LambdaQueryWrapper
<
RegUnitIc
>().
eq
(
RegUnitIc:
:
getUnitCode
,
unitCode
));
regUnitInfoDto
.
setRegUnitIc
(
Bean
.
toModel
(
regUnitIc
,
new
RegUnitIcDto
()));
if
(
regUnitIc
==
null
)
{
// 2.1 使用单位调用行政许可系统接口进行查询工商信息
// MultiValueMap<String, String> headers = new HttpHeaders();
// MultiValueMap<String, String> headers = new HttpHeaders();
// headers.add("product","AMOS_STUDIO_WEB");
// headers.add("product","AMOS_STUDIO_WEB");
// headers.add("appKey","AMOS_STUDIO");
// headers.add("appKey","AMOS_STUDIO");
...
@@ -262,8 +254,6 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
...
@@ -262,8 +254,6 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
// RequestContext.setToken();
// RequestContext.setToken();
// RequestContext.setAppKey();
// RequestContext.setAppKey();
// RequestContext.setProduct();
// RequestContext.setProduct();
Map
<
String
,
Object
>
resultMap
=
accessFeignService
.
getData
(
unitCode
).
getResult
();
// RequestEntity requestEntity = new RequestEntity(
// RequestEntity requestEntity = new RequestEntity(
// null, //body部分数据
// null, //body部分数据
// headers, //头
// headers, //头
...
@@ -271,12 +261,16 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
...
@@ -271,12 +261,16 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
// URI.create("/accessapi/business/getData"));
// URI.create("/accessapi/business/getData"));
// ResponseEntity<JSONObject> responseEntity = restTemplate.exchange(requestEntity,JSONObject.class);
// ResponseEntity<JSONObject> responseEntity = restTemplate.exchange(requestEntity,JSONObject.class);
// JSONObject result = responseEntity.getBody();
// JSONObject result = responseEntity.getBody();
// 2.1 使用单位调用行政许可系统接口进行查询工商信息
Map
<
String
,
Object
>
resultMap
=
accessFeignService
.
getData
(
unitCode
).
getResult
();
if
(!
ValidationUtil
.
isEmpty
(
resultMap
)){
if
(!
ValidationUtil
.
isEmpty
(
resultMap
)){
// 2.2 工商信息组装
// 2.2 工商信息组装
String
area
=
String
.
valueOf
(
resultMap
.
get
(
"area"
));
String
area
=
String
.
valueOf
(
resultMap
.
get
(
"area"
));
String
city
=
area
.
substring
(
0
,
area
.
indexOf
(
"市"
)+
1
);
String
city
=
area
.
substring
(
0
,
area
.
indexOf
(
"市"
)+
1
);
String
district
=
area
.
substring
(
city
.
length
());
String
district
=
area
.
substring
(
city
.
length
());
if
(
district
.
equals
(
"高新区"
)){
district
=
"雁塔区"
;
}
regUnitInfoDto
.
setCity
(
city
);
regUnitInfoDto
.
setCity
(
city
);
regUnitInfoDto
.
setDistrict
(
district
);
regUnitInfoDto
.
setDistrict
(
district
);
regUnitInfoDto
.
setStree
(
String
.
valueOf
(
resultMap
.
get
(
"street"
)));
regUnitInfoDto
.
setStree
(
String
.
valueOf
(
resultMap
.
get
(
"street"
)));
...
@@ -285,13 +279,35 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
...
@@ -285,13 +279,35 @@ public class RegUnitInfoServiceImpl extends BaseService<RegUnitInfoDto, RegUnitI
regUnitInfoDto
.
setUnitCode
(
String
.
valueOf
(
resultMap
.
get
(
"creditCode"
)));
regUnitInfoDto
.
setUnitCode
(
String
.
valueOf
(
resultMap
.
get
(
"creditCode"
)));
regUnitInfoDto
.
setName
(
String
.
valueOf
(
resultMap
.
get
(
"unitName"
)));
regUnitInfoDto
.
setName
(
String
.
valueOf
(
resultMap
.
get
(
"unitName"
)));
regUnitInfoDto
.
setLegalPerson
(
String
.
valueOf
(
resultMap
.
get
(
"legalPeople"
)));
regUnitInfoDto
.
setLegalPerson
(
String
.
valueOf
(
resultMap
.
get
(
"legalPeople"
)));
}
}
String
industryName
=
iDataDictionaryService
.
getByCode
(
String
.
valueOf
(
resultMap
.
get
(
"industryCode"
)),
"HYXLDM"
).
getName
();
String
approveDate
=
String
.
valueOf
(
resultMap
.
get
(
"approval_time"
));
approveDate
=
approveDate
.
contains
(
"年"
)?
approveDate
.
replace
(
"年"
,
"-"
):
approveDate
;
approveDate
=
approveDate
.
contains
(
"月"
)?
approveDate
.
replace
(
"月"
,
"-"
):
approveDate
;
approveDate
=
approveDate
.
contains
(
"日"
)?
approveDate
.
replace
(
"日"
,
"-"
):
approveDate
;
RegUnitIcDto
regUnitIcDto
=
new
RegUnitIcDto
();
regUnitIcDto
.
setUnitCode
(
regUnitInfoDto
.
getUnitCode
());
try
{
regUnitIcDto
.
setApprovedDate
(
DateUtils
.
dateParse
(
approveDate
,
"yyyy-MM-dd"
));
}
catch
(
ParseException
e
)
{
e
.
printStackTrace
();
}
regUnitIcDto
.
setUnitName
(
regUnitInfoDto
.
getName
());
regUnitIcDto
.
setRegisteredOrgan
(
String
.
valueOf
(
resultMap
.
get
(
"registration_authority"
)));
regUnitIcDto
.
setBusinessState
(
String
.
valueOf
(
resultMap
.
get
(
"operating_status"
)));
regUnitIcDto
.
setProvince
(
"陕西省"
);
regUnitIcDto
.
setCity
(
regUnitInfoDto
.
getCity
());
regUnitIcDto
.
setDistrict
(
regUnitInfoDto
.
getDistrict
());
regUnitIcDto
.
setStree
(
regUnitInfoDto
.
getStree
());
regUnitIcDto
.
setCommunity
(
regUnitInfoDto
.
getCommunity
());
regUnitIcDto
.
setAddress
(
regUnitInfoDto
.
getAddress
());
regUnitIcDto
.
setLegalPerson
(
regUnitInfoDto
.
getLegalPerson
());
regUnitIcDto
.
setIndustryName
(
industryName
);
regUnitInfoDto
.
setRegUnitIc
(
regUnitIcDto
);
}
else
{
}
else
{
RegUnitIc
regUnitIc
=
regUnitIcService
regUnitInfoDto
.
setRegUnitIc
(
new
RegUnitIcDto
());
.
getOne
(
new
LambdaQueryWrapper
<
RegUnitIc
>().
eq
(
RegUnitIc:
:
getUnitCode
,
unitCode
));
regUnitInfoDto
.
setRegUnitIc
(
Bean
.
toModel
(
regUnitIc
,
new
RegUnitIcDto
()));
}
}
// 2.3 许可信息组装
// 2.3 许可信息组装
List
<
BaseUnitLicence
>
unitLicences
=
baseUnitLicenceService
List
<
BaseUnitLicence
>
unitLicences
=
baseUnitLicenceService
.
list
(
new
LambdaQueryWrapper
<
BaseUnitLicence
>().
eq
(
BaseUnitLicence:
:
getUnitCode
,
unitCode
));
.
list
(
new
LambdaQueryWrapper
<
BaseUnitLicence
>().
eq
(
BaseUnitLicence:
:
getUnitCode
,
unitCode
));
...
...
amos-boot-system-tzs/amos-boot-module-tzs-biz/src/main/resources/logback-dev.xml
View file @
e32836e9
...
@@ -24,6 +24,11 @@
...
@@ -24,6 +24,11 @@
<pattern>
${LOG_PATTERN}
</pattern>
<pattern>
${LOG_PATTERN}
</pattern>
</encoder>
</encoder>
</appender>
</appender>
<!-- <!– ELK管理 –>-->
<!-- <appender name="ELK" class="net.logstash.logback.appender.LogstashTcpSocketAppender">-->
<!-- <destination>172.16.10.210:4560</destination>-->
<!-- <encoder charset="UTF-8" class="net.logstash.logback.encoder.LogstashEncoder"/>-->
<!-- </appender>-->
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
...
@@ -48,5 +53,6 @@
...
@@ -48,5 +53,6 @@
<root
level=
"DEBUG"
>
<root
level=
"DEBUG"
>
<!-- <appender-ref ref="FILE" /> -->
<!-- <appender-ref ref="FILE" /> -->
<appender-ref
ref=
"STDOUT"
/>
<appender-ref
ref=
"STDOUT"
/>
<!-- <appender-ref ref="ELK" />-->
</root>
</root>
</configuration>
</configuration>
\ No newline at end of file
amos-boot-system-tzs/amos-boot-module-tzs-biz/src/main/resources/logback-dev2.xml
View file @
e32836e9
...
@@ -24,6 +24,11 @@
...
@@ -24,6 +24,11 @@
<pattern>
${LOG_PATTERN}
</pattern>
<pattern>
${LOG_PATTERN}
</pattern>
</encoder>
</encoder>
</appender>
</appender>
<!-- ELK管理 -->
<appender
name=
"ELK"
class=
"net.logstash.logback.appender.LogstashTcpSocketAppender"
>
<destination>
172.16.10.210:4560
</destination>
<encoder
charset=
"UTF-8"
class=
"net.logstash.logback.encoder.LogstashEncoder"
/>
</appender>
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
...
@@ -43,10 +48,11 @@
...
@@ -43,10 +48,11 @@
<logger
name=
"org.apache.activemq"
level=
"INFO"
/>
<logger
name=
"org.apache.activemq"
level=
"INFO"
/>
<logger
name=
"org.typroject"
level=
"INFO"
/>
<logger
name=
"org.typroject"
level=
"INFO"
/>
<logger
name=
"com.yeejoin"
level=
"INFO"
/>
<logger
name=
"com.yeejoin"
level=
"INFO"
/>
<logger
name=
"org.apache.http"
level=
"ERROR"
/>
<!-- 日志输出级别 -->
<!-- 日志输出级别 -->
<root
level=
"DEBUG"
>
<root
level=
"DEBUG"
>
<!-- <appender-ref ref="FILE" /> -->
<!-- <appender-ref ref="FILE" /> -->
<appender-ref
ref=
"STDOUT"
/>
<appender-ref
ref=
"STDOUT"
/>
<!-- <appender-ref ref="ELK" />-->
</root>
</root>
</configuration>
</configuration>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment