Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
bigdatainterservice
Overview
Overview
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
曹鹏
bigdatainterservice
Commits
3fd69a86
Commit
3fd69a86
authored
Apr 28, 2019
by
caojingji
Browse files
Options
Browse Files
Download
Plain Diff
修改新版网安对接接口 调整返回的参数格式
parents
ea366f00
cf853c4d
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
434 additions
and
13 deletions
+434
-13
src/main/java/com/founder/interservice/BigdatainterserviceApplication.java
+1
-1
src/main/java/com/founder/interservice/config/DataSourceCqxzConfig.java
+40
-0
src/main/java/com/founder/interservice/controller/DataController.java
+167
-4
src/main/java/com/founder/interservice/controller/MinistrySuspectInfoController.java
+3
-3
src/main/java/com/founder/interservice/controller/TzxxlydyController.java
+36
-0
src/main/java/com/founder/interservice/mapper/cqxz/TbStAsjMapper.java
+15
-0
src/main/java/com/founder/interservice/mapper/cqxz/TbTzxxjqTzxxlydyMapper.java
+14
-0
src/main/java/com/founder/interservice/model/TbStAsj.java
+15
-0
src/main/java/com/founder/interservice/model/TbTzxxjqTzxxlydy.java
+35
-0
src/main/java/com/founder/interservice/qgzyfw/action/CallDygabxxfw.java
+3
-2
src/main/java/com/founder/interservice/service/DataService.java
+1
-0
src/main/java/com/founder/interservice/service/TbTzxxjqTzxxlydyService.java
+15
-0
src/main/java/com/founder/interservice/service/impl/DataServiceImpl.java
+10
-3
src/main/java/com/founder/interservice/service/impl/TbTzxxjqTzxxlydyServiceImpl.java
+46
-0
src/main/resources/application-prod.yml
+6
-0
src/main/resources/mybatis/mapper/cqxz/TbStAsjMapper.xml
+8
-0
src/main/resources/mybatis/mapper/cqxz/TbTzxxjqTzxxlydyMapper.xml
+17
-0
src/main/resources/mybatis/mapper/xzxt/RelationMapper.xml
+2
-0
No files found.
src/main/java/com/founder/interservice/BigdatainterserviceApplication.java
View file @
3fd69a86
...
@@ -13,7 +13,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement;
...
@@ -13,7 +13,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement;
@EnableTransactionManagement
//开启事务管理
@EnableTransactionManagement
//开启事务管理
@EnableScheduling
//开启定时任务
@EnableScheduling
//开启定时任务
@EnableAsync
//开启异步
@EnableAsync
//开启异步
@MapperScan
({
"com.founder.interservice.mapper.xzxt"
,
"com.founder.interservice.mapper.gxzxt"
})
@MapperScan
({
"com.founder.interservice.mapper.xzxt"
,
"com.founder.interservice.mapper.gxzxt"
,
"com.founder.interservice.mapper.cqxz"
})
public
class
BigdatainterserviceApplication
{
public
class
BigdatainterserviceApplication
{
public
static
void
main
(
String
[]
args
)
{
public
static
void
main
(
String
[]
args
)
{
SpringApplication
.
run
(
BigdatainterserviceApplication
.
class
,
args
);
SpringApplication
.
run
(
BigdatainterserviceApplication
.
class
,
args
);
...
...
src/main/java/com/founder/interservice/config/DataSourceCqxzConfig.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
config
;
import
org.apache.ibatis.session.SqlSessionFactory
;
import
org.mybatis.spring.SqlSessionFactoryBean
;
import
org.mybatis.spring.SqlSessionTemplate
;
import
org.mybatis.spring.annotation.MapperScan
;
import
org.springframework.beans.factory.annotation.Qualifier
;
import
org.springframework.boot.autoconfigure.jdbc.DataSourceBuilder
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.core.io.support.PathMatchingResourcePatternResolver
;
import
javax.sql.DataSource
;
/**
* Created by liuys on 2019/4/24.
*/
@Configuration
@MapperScan
(
basePackages
=
"com.founder.interservice.mapper.cqxz"
,
sqlSessionTemplateRef
=
"cqxzSqlSessionTemplate"
)
public
class
DataSourceCqxzConfig
{
@Bean
(
name
=
"cqxzDataSource"
)
@ConfigurationProperties
(
prefix
=
"spring.datasource.cqxz"
)
public
DataSource
cqxzDataSource
()
{
return
DataSourceBuilder
.
create
().
build
();
}
@Bean
(
name
=
"cqxzSqlSessionFactory"
)
public
SqlSessionFactory
cqxzSqlSessionFactory
(
@Qualifier
(
"cqxzDataSource"
)
DataSource
dataSource
)
throws
Exception
{
SqlSessionFactoryBean
bean
=
new
SqlSessionFactoryBean
();
bean
.
setDataSource
(
dataSource
);
bean
.
setMapperLocations
(
new
PathMatchingResourcePatternResolver
().
getResources
(
"classpath:mybatis/mapper/cqxz/*.xml"
));
return
bean
.
getObject
();
}
@Bean
(
name
=
"cqxzSqlSessionTemplate"
)
public
SqlSessionTemplate
cqxzSqlSessionTemplate
(
@Qualifier
(
"cqxzSqlSessionFactory"
)
SqlSessionFactory
sqlSessionFactory
)
throws
Exception
{
return
new
SqlSessionTemplate
(
sqlSessionFactory
);
}
}
src/main/java/com/founder/interservice/controller/DataController.java
View file @
3fd69a86
...
@@ -6,6 +6,8 @@ import com.founder.interservice.VO.ResultVO;
...
@@ -6,6 +6,8 @@ import com.founder.interservice.VO.ResultVO;
import
com.founder.interservice.VO.TrackVO
;
import
com.founder.interservice.VO.TrackVO
;
import
com.founder.interservice.enums.ResultEnum
;
import
com.founder.interservice.enums.ResultEnum
;
import
com.founder.interservice.model.AutoTbStRy
;
import
com.founder.interservice.model.AutoTbStRy
;
import
com.founder.interservice.model.Relation
;
import
com.founder.interservice.model.ResultObj
;
import
com.founder.interservice.model.Track
;
import
com.founder.interservice.model.Track
;
import
com.founder.interservice.querymodel.RelationFilter
;
import
com.founder.interservice.querymodel.RelationFilter
;
import
com.founder.interservice.querymodel.TrackFilter
;
import
com.founder.interservice.querymodel.TrackFilter
;
...
@@ -13,20 +15,19 @@ import com.founder.interservice.recordLog.model.Querylog;
...
@@ -13,20 +15,19 @@ import com.founder.interservice.recordLog.model.Querylog;
import
com.founder.interservice.recordLog.service.RecordLogService
;
import
com.founder.interservice.recordLog.service.RecordLogService
;
import
com.founder.interservice.service.DataService
;
import
com.founder.interservice.service.DataService
;
import
com.founder.interservice.service.IphoneTrackService
;
import
com.founder.interservice.service.IphoneTrackService
;
import
com.founder.interservice.service.PushWaDataService
;
import
com.founder.interservice.util.*
;
import
com.founder.interservice.util.*
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.servlet.ModelAndView
;
import
org.springframework.web.servlet.ModelAndView
;
import
javax.servlet.http.HttpServletResponse
;
import
javax.servlet.http.HttpServletResponse
;
import
java.net.URLEncoder
;
import
java.net.URLEncoder
;
import
java.util.ArrayList
;
import
java.util.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
/**
* @ClassName: DateController
* @ClassName: DateController
...
@@ -46,6 +47,8 @@ public class DataController {
...
@@ -46,6 +47,8 @@ public class DataController {
private
RecordLogService
recordLogService
;
private
RecordLogService
recordLogService
;
@Autowired
@Autowired
private
IphoneTrackService
iphoneTrackService
;
private
IphoneTrackService
iphoneTrackService
;
@Autowired
private
PushWaDataService
pushWaDataService
;
@Value
(
"${wabigdata.pgis.url}"
)
@Value
(
"${wabigdata.pgis.url}"
)
private
String
PGIS_URL
;
private
String
PGIS_URL
;
@Value
(
"${wabigdata.pgis_title.url}"
)
@Value
(
"${wabigdata.pgis_title.url}"
)
...
@@ -689,4 +692,164 @@ public class DataController {
...
@@ -689,4 +692,164 @@ public class DataController {
return
trackVOS
;
return
trackVOS
;
}
}
@RequestMapping
(
value
=
"/queryRelationsBySfzh"
)
@ResponseBody
public
JSONObject
queryRelationsBySfzh
(
String
sfzh
,
String
type
){
JSONObject
resultObj
=
new
JSONObject
();
try
{
Relation
relation
=
new
Relation
();
relation
.
setObjectfromtype
(
"1"
);
relation
.
setObjectfromvalue
(
sfzh
);
relation
.
setObjecttotype
(
type
);
List
<
Relation
>
resultList
=
dataService
.
queryRelationList
(
relation
);
if
(!
resultList
.
isEmpty
()
&&
resultList
!=
null
){
resultObj
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
resultObj
.
put
(
"message"
,
ResultEnum
.
SUCCESS
.
getMessage
());
}
else
{
resultObj
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
resultObj
.
put
(
"message"
,
"无数据"
);
}
resultObj
.
put
(
"dataList"
,
resultList
);
}
catch
(
Exception
e
){
e
.
printStackTrace
();
resultObj
.
put
(
"code"
,
ResultEnum
.
RESULT_ERROR
.
getCode
());
resultObj
.
put
(
"message"
,
ResultEnum
.
RESULT_ERROR
.
getMessage
());
}
return
resultObj
;
}
@RequestMapping
(
value
=
"/queryJdAndThxxBySfzh"
)
@ResponseBody
public
JSONObject
queryJdAndThxxBySfzh
(
String
sfzh
,
String
type
,
String
caseId
,
String
caseName
){
List
<
String
>
sjhmTypes
=
Arrays
.
asList
(
"20"
,
"4394"
,
"3996"
,
"6003"
);
//手机号码类别
List
<
String
>
jdxxTypes
=
Arrays
.
asList
(
"6095"
,
"6096"
);
//快递类别
List
<
String
>
thgxTypes
=
Arrays
.
asList
(
"45878"
,
"4103"
,
"4396"
,
"4088"
,
"45936"
,
"45935"
);
//同户关系类别45878:母亲,4103:父亲,4396:母子关系,4088:配偶,45936:母子,45935:父子
JSONObject
jsonObejct
=
new
JSONObject
();
JSONObject
jsonObj
=
new
JSONObject
();
List
<
Relation
>
relationList
=
new
ArrayList
<>();
try
{
if
(
type
.
equals
(
"thxx"
)){
String
thxxResult
=
pushWaDataService
.
pushRelations
(
caseId
,
caseName
,
caseId
,
sfzh
);
if
(
null
!=
thxxResult
&&
thxxResult
.
startsWith
(
"{"
)){
jsonObj
=
JSONObject
.
parseObject
(
thxxResult
);
}
if
(
jsonObj
!=
null
){
String
dataList
=
jsonObj
.
getString
(
"data"
);
JSONObject
dataObj
=
JSONObject
.
parseObject
(
dataList
);
if
(
dataObj
!=
null
){
JSONArray
childrens
=
dataObj
.
getJSONArray
(
"data"
);
if
(
childrens
!=
null
&&
childrens
.
size
()
>
0
){
for
(
int
i
=
0
;
i
<
childrens
.
size
();
i
++){
JSONObject
children
=
childrens
.
getJSONObject
(
i
);
if
(
thgxTypes
.
contains
(
children
.
getString
(
"relativeType"
))){
//关系
Relation
relation
=
new
Relation
();
relation
.
setObjecttotype
(
children
.
getString
(
"objectToType"
));
relation
.
setObjecttotypename
(
children
.
getString
(
"objectToTypeName"
));
relation
.
setObjecttovalue
(
children
.
getString
(
"objectToValue"
));
relation
.
setObjectfromtype
(
children
.
getString
(
"objectFromType"
));
relation
.
setObjectfromvalue
(
children
.
getString
(
"objectFromValue"
));
relation
.
setObjectfromtypename
(
children
.
getString
(
"objectFromTypeName"
));
relation
.
setRelativetype
(
children
.
getString
(
"relativeType"
));
relation
.
setRelativetypename
(
children
.
getString
(
"relativeTypeName"
));
relationList
.
add
(
relation
);
}
}
}
relationList
=
removeJSonObject
(
relationList
);
}
}
}
else
if
(
type
.
equals
(
"jdxx"
)){
String
thxxResult
=
pushWaDataService
.
pushRelations
(
caseId
,
caseName
,
caseId
,
sfzh
);
if
(
null
!=
thxxResult
&&
thxxResult
.
startsWith
(
"{"
)){
jsonObj
=
JSONObject
.
parseObject
(
thxxResult
);
}
if
(
jsonObj
!=
null
){
String
dataList
=
jsonObj
.
getString
(
"data"
);
JSONObject
dataObj
=
JSONObject
.
parseObject
(
dataList
);
if
(
dataObj
!=
null
){
JSONArray
childrens
=
dataObj
.
getJSONArray
(
"data"
);
if
(
childrens
!=
null
&&
childrens
.
size
()
>
0
){
for
(
int
i
=
0
;
i
<
childrens
.
size
();
i
++){
JSONObject
children
=
childrens
.
getJSONObject
(
i
);
if
(
sjhmTypes
.
contains
(
children
.
getString
(
"relativeType"
))){
//关系
String
sjhm
=
getSjhmsList
(
children
);
JSONObject
jsonObject
=
null
;
if
(
sjhm
!=
null
){
String
jdxxResult
=
pushWaDataService
.
pushRelations
(
caseId
,
caseName
,
caseId
,
sjhm
);
if
(
null
!=
jdxxResult
&&
jdxxResult
.
startsWith
(
"{"
)){
jsonObject
=
JSONObject
.
parseObject
(
jdxxResult
);
}
if
(
jsonObject
!=
null
){
String
jdxxList
=
jsonObject
.
getString
(
"data"
);
JSONObject
jdxxObj
=
JSONObject
.
parseObject
(
jdxxList
);
if
(
jdxxObj
!=
null
){
JSONArray
jdxxChildrenList
=
jdxxObj
.
getJSONArray
(
"data"
);
if
(
jdxxChildrenList
!=
null
&&
jdxxChildrenList
.
size
()
>
0
){
for
(
int
j
=
0
;
j
<
jdxxChildrenList
.
size
();
j
++){
JSONObject
jdxxChildrens
=
jdxxChildrenList
.
getJSONObject
(
j
);
if
(
jdxxTypes
.
contains
(
jdxxChildrens
.
getString
(
"relativeType"
))){
//关系
Relation
relation
=
new
Relation
();
relation
.
setObjecttotype
(
jdxxChildrens
.
getString
(
"objectToType"
));
relation
.
setObjecttotypename
(
jdxxChildrens
.
getString
(
"objectToTypeName"
));
relation
.
setObjecttovalue
(
jdxxChildrens
.
getString
(
"objectToValue"
));
relation
.
setObjectfromtype
(
jdxxChildrens
.
getString
(
"objectFromType"
));
relation
.
setObjectfromvalue
(
jdxxChildrens
.
getString
(
"objectFromValue"
));
relation
.
setObjectfromtypename
(
jdxxChildrens
.
getString
(
"objectFromTypeName"
));
relation
.
setRelativetype
(
jdxxChildrens
.
getString
(
"relativeType"
));
relation
.
setRelativetypename
(
jdxxChildrens
.
getString
(
"relativeTypeName"
));
relationList
.
add
(
relation
);
}
}
}
}
}
}
}
}
}
}
}
}
if
(!
relationList
.
isEmpty
()
&&
relationList
!=
null
){
jsonObejct
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
jsonObejct
.
put
(
"message"
,
ResultEnum
.
SUCCESS
.
getMessage
());
}
else
{
jsonObejct
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
jsonObejct
.
put
(
"message"
,
"无数据"
);
}
jsonObejct
.
put
(
"dataList"
,
relationList
);
}
catch
(
Exception
e
){
e
.
printStackTrace
();
jsonObejct
.
put
(
"code"
,
ResultEnum
.
RESULT_ERROR
.
getCode
());
jsonObejct
.
put
(
"message"
,
ResultEnum
.
RESULT_ERROR
.
getMessage
());
}
return
jsonObejct
;
}
/**
* 提取手机号码的关联信息
* @return
*/
private
String
getSjhmsList
(
JSONObject
children
){
String
sjhm
=
children
.
getString
(
"objectToValue"
);
//可能会有7位或者10位的手机号码或者电话号码,但是这儿统一只展示11位的手机号码或者电话号码
if
(
sjhm
.
length
()
==
11
||
sjhm
.
length
()
==
8
||
sjhm
.
length
()
==
13
){
return
sjhm
;
}
return
null
;
}
@Async
public
List
<
Relation
>
removeJSonObject
(
List
<
Relation
>
jsonObjects
){
Set
<
Relation
>
set
=
new
TreeSet
<
Relation
>(
new
Comparator
<
Relation
>()
{
@Override
public
int
compare
(
Relation
o1
,
Relation
o2
)
{
return
o1
.
getObjecttovalue
().
compareTo
(
o2
.
getObjecttovalue
());
}
});
set
.
addAll
(
jsonObjects
);
return
new
ArrayList
<
Relation
>(
set
);
}
}
}
src/main/java/com/founder/interservice/controller/MinistrySuspectInfoController.java
View file @
3fd69a86
...
@@ -186,16 +186,16 @@ public class MinistrySuspectInfoController {
...
@@ -186,16 +186,16 @@ public class MinistrySuspectInfoController {
jsonArray
.
add
(
jsonObject
);
jsonArray
.
add
(
jsonObject
);
Object
[]
os
=
jsonArray
.
toArray
();
Object
[]
os
=
jsonArray
.
toArray
();
Map
<
String
,
Object
>
mapQg
=
call
.
getGabZyInfoByJyaq
(
"asj"
,
os
,
gabConfig
);
Map
<
String
,
Object
>
mapQg
=
call
.
getGabZyInfoByJyaq
(
"asj"
,
os
,
gabConfig
);
List
<
Map
<
String
,
Object
>>
asjbh
List
=
(
List
<
Map
<
String
,
Object
>>)
mapQg
.
get
(
"dataResult"
);
result
List
=
(
List
<
Map
<
String
,
Object
>>)
mapQg
.
get
(
"dataResult"
);
if
(!
asjbhList
.
isEmpty
()
&&
asjbh
List
!=
null
){
if
(!
resultList
.
isEmpty
()
&&
result
List
!=
null
){
resultObj
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
resultObj
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
resultObj
.
put
(
"message"
,
ResultEnum
.
SUCCESS
.
getMessage
());
resultObj
.
put
(
"message"
,
ResultEnum
.
SUCCESS
.
getMessage
());
}
else
{
}
else
{
resultObj
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
resultObj
.
put
(
"code"
,
ResultEnum
.
SUCCESS
.
getCode
());
resultObj
.
put
(
"message"
,
"无数据"
);
resultObj
.
put
(
"message"
,
"无数据"
);
}
}
resultObj
.
put
(
"dataList"
,
asjbh
List
);
resultObj
.
put
(
"dataList"
,
result
List
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
resultObj
.
put
(
"code"
,
ResultEnum
.
RESULT_ERROR
.
getCode
());
resultObj
.
put
(
"code"
,
ResultEnum
.
RESULT_ERROR
.
getCode
());
...
...
src/main/java/com/founder/interservice/controller/TzxxlydyController.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
controller
;
import
com.founder.interservice.model.TbStAsj
;
import
com.founder.interservice.model.TbTzxxjqTzxxlydy
;
import
com.founder.interservice.service.TbTzxxjqTzxxlydyService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.CrossOrigin
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
java.util.List
;
/**
* Created by liuys on 2019/4/24.
*/
@Controller
@CrossOrigin
public
class
TzxxlydyController
{
@Autowired
private
TbTzxxjqTzxxlydyService
tzxxlydyService
;
@RequestMapping
(
"/getTzxxlydy"
)
@ResponseBody
public
List
<
TbTzxxjqTzxxlydy
>
getTzxxlydyByAsjbh
(
@Validated
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
){
return
tzxxlydyService
.
findTzxxlydyByAsjbh
(
tbTzxxjqTzxxlydy
);
}
@RequestMapping
(
"/getBshGlaj"
)
@ResponseBody
public
List
<
TbStAsj
>
getBshGlajByBsh
(
@Validated
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
){
return
tzxxlydyService
.
findAsjxxByBsh
(
tbTzxxjqTzxxlydy
);
}
}
src/main/java/com/founder/interservice/mapper/cqxz/TbStAsjMapper.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
mapper
.
cqxz
;
import
com.founder.interservice.model.TbStAsj
;
import
org.springframework.stereotype.Repository
;
import
org.springframework.validation.annotation.Validated
;
import
java.util.List
;
/**
* Created by liuys on 2019/4/25.
*/
@Repository
public
interface
TbStAsjMapper
{
List
<
TbStAsj
>
findAsjxxByAsjbh
(
String
_parameter
);
}
src/main/java/com/founder/interservice/mapper/cqxz/TbTzxxjqTzxxlydyMapper.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
mapper
.
cqxz
;
import
com.founder.interservice.model.TbTzxxjqTzxxlydy
;
import
org.springframework.stereotype.Repository
;
import
java.util.List
;
/**
* Created by liuys on 2019/4/24.
*/
@Repository
public
interface
TbTzxxjqTzxxlydyMapper
{
public
List
<
TbTzxxjqTzxxlydy
>
findTzxxlydyByAsjbh
(
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
);
}
src/main/java/com/founder/interservice/model/TbStAsj.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
model
;
import
lombok.Data
;
/**
* Created by liuys on 2019/4/25.
*/
@Data
public
class
TbStAsj
{
private
String
asjbh
;
private
String
ajmc
;
private
String
asjfssjAsjfskssj
;
private
String
asjfsddDzmc
;
private
String
jyaq
;
}
src/main/java/com/founder/interservice/model/TbTzxxjqTzxxlydy.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
model
;
//
import
lombok.Data
;
import
org.hibernate.annotations.DynamicUpdate
;
import
javax.persistence.Entity
;
import
javax.persistence.Table
;
import
java.util.Date
;
/**
* Created by liuys on 2019/4/24.
*/
@Data
public
class
TbTzxxjqTzxxlydy
{
private
String
rcdid
;
//主键编号
private
String
ztbs
;
// 主题标示(特征信息类型 用固定的字符,表示特定主题,如aj)
private
String
bshlx
;
// 对应的标示号类型(内容要和标示号类型代码表中的一致)
private
String
zjzdmc
;
// 该表的主键字段名称(配置案件编号,线索编号等字段的名称)
private
Date
afsj
;
//
private
String
lrr
;
// 录入人
private
Date
lrsj
;
// 录入时间
private
String
lrdwdm
;
// 录入单位代码
private
String
lrdwmc
;
// 录入单位名称
private
String
gxr
;
// 改写人
private
Date
gxsj
;
// 改写时间
private
String
scbz
;
// 删除标志
private
String
zjbh
;
// 该表的主键编号
private
String
gjc
;
// 关键特征信息
private
String
bm
;
// 特征信息来源表名
private
String
ip
;
// ip地址
private
String
gxdwdm
;
// 改写单位代码
private
String
gxdwmc
;
// 改写单位名称
private
String
cxlx
;
//查询类型01表示查询标识号,02表示根据标识号查关联案件信息
}
src/main/java/com/founder/interservice/qgzyfw/action/CallDygabxxfw.java
View file @
3fd69a86
...
@@ -38,6 +38,7 @@ public class CallDygabxxfw{
...
@@ -38,6 +38,7 @@ public class CallDygabxxfw{
//根据条件调取部级资源-主方法
//根据条件调取部级资源-主方法
public
Map
getGabZyInfoByJyaq
(
String
zylx
,
Object
[]
os
,
GabConfig
gabConfig
){
//zylx:查询资源类型,os:参数
public
Map
getGabZyInfoByJyaq
(
String
zylx
,
Object
[]
os
,
GabConfig
gabConfig
){
//zylx:查询资源类型,os:参数
Map
dataMap
=
new
HashMap
();
String
responseId
=
""
;
//联动服务方id
String
responseId
=
""
;
//联动服务方id
String
bizParamXml
=
""
;
//发送查询所需的xml字符串
String
bizParamXml
=
""
;
//发送查询所需的xml字符串
if
(
"asj"
.
equals
(
zylx
)){
if
(
"asj"
.
equals
(
zylx
)){
...
@@ -94,10 +95,10 @@ public class CallDygabxxfw{
...
@@ -94,10 +95,10 @@ public class CallDygabxxfw{
//System.out.println("查询类别=="+zylx+"获取的resultStr="+resultStr);
//System.out.println("查询类别=="+zylx+"获取的resultStr="+resultStr);
if
(!
StringUtil
.
ckeckEmpty
(
resultStr
)){
if
(!
StringUtil
.
ckeckEmpty
(
resultStr
)){
resultStr
=
resultStr
.
substring
(
resultStr
.
indexOf
(
"<Data>"
)+
6
,
resultStr
.
indexOf
(
"</Data>"
));
resultStr
=
resultStr
.
substring
(
resultStr
.
indexOf
(
"<Data>"
)+
6
,
resultStr
.
indexOf
(
"</Data>"
));
D
ataMap
=
returnXmlMap
(
xmlStr2Document
(
resultStr
),
zylx
);
d
ataMap
=
returnXmlMap
(
xmlStr2Document
(
resultStr
),
zylx
);
//System.out.println("查询类别=="+zylx+"裁剪后的resultStr生成的DataMap="+DataMap);
//System.out.println("查询类别=="+zylx+"裁剪后的resultStr生成的DataMap="+DataMap);
}
}
return
D
ataMap
;
return
d
ataMap
;
}
}
/**
/**
* 调取全国的28个资源服务
* 调取全国的28个资源服务
...
...
src/main/java/com/founder/interservice/service/DataService.java
View file @
3fd69a86
package
com
.
founder
.
interservice
.
service
;
package
com
.
founder
.
interservice
.
service
;
import
com.alibaba.fastjson.JSONObject
;
import
com.founder.interservice.exception.InterServiceException
;
import
com.founder.interservice.exception.InterServiceException
;
import
com.founder.interservice.model.Relation
;
import
com.founder.interservice.model.Relation
;
import
com.founder.interservice.model.Track
;
import
com.founder.interservice.model.Track
;
...
...
src/main/java/com/founder/interservice/service/TbTzxxjqTzxxlydyService.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
service
;
import
com.founder.interservice.model.TbStAsj
;
import
com.founder.interservice.model.TbTzxxjqTzxxlydy
;
import
java.util.List
;
/**
* Created by liuys on 2019/4/24.
*/
public
interface
TbTzxxjqTzxxlydyService
{
List
<
TbTzxxjqTzxxlydy
>
findTzxxlydyByAsjbh
(
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
);
List
<
TbStAsj
>
findAsjxxByBsh
(
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
);
}
src/main/java/com/founder/interservice/service/impl/DataServiceImpl.java
View file @
3fd69a86
package
com
.
founder
.
interservice
.
service
.
impl
;
package
com
.
founder
.
interservice
.
service
.
impl
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.founder.interservice.enums.ResultEnum
;
import
com.founder.interservice.enums.ResultEnum
;
import
com.founder.interservice.exception.InterServiceException
;
import
com.founder.interservice.exception.InterServiceException
;
import
com.founder.interservice.model.Relation
;
import
com.founder.interservice.model.Relation
;
import
com.founder.interservice.model.ResultObj
;
import
com.founder.interservice.model.Track
;
import
com.founder.interservice.model.Track
;
import
com.founder.interservice.querymodel.RelationFilter
;
import
com.founder.interservice.querymodel.RelationFilter
;
import
com.founder.interservice.querymodel.TrackFilter
;
import
com.founder.interservice.querymodel.TrackFilter
;
import
com.founder.interservice.service.DataService
;
import
com.founder.interservice.service.DataService
;
import
com.founder.interservice.util.HttpUtil
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.founder.interservice.mapper.xzxt.RelationMapper
;
import
com.founder.interservice.mapper.xzxt.RelationMapper
;
import
com.founder.interservice.mapper.xzxt.TrackMapper
;
import
com.founder.interservice.mapper.xzxt.TrackMapper
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.*
;
import
java.util.Map
;
/**
/**
* @ClassName: DataServiceImpl
* @ClassName: DataServiceImpl
...
@@ -25,6 +29,8 @@ import java.util.Map;
...
@@ -25,6 +29,8 @@ import java.util.Map;
@Service
@Service
public
class
DataServiceImpl
implements
DataService
{
public
class
DataServiceImpl
implements
DataService
{
@Value
(
"${wabigdata.relationGetAll.url}"
)
private
String
relationGetAll_url
;
@Autowired
@Autowired
private
RelationMapper
relationMapper
;
private
RelationMapper
relationMapper
;
@Autowired
@Autowired
...
@@ -141,4 +147,5 @@ public class DataServiceImpl implements DataService {
...
@@ -141,4 +147,5 @@ public class DataServiceImpl implements DataService {
int
total
=
relationMapper
.
selectRelatNum
(
relationFilter
);
int
total
=
relationMapper
.
selectRelatNum
(
relationFilter
);
return
total
;
return
total
;
}
}
}
}
src/main/java/com/founder/interservice/service/impl/TbTzxxjqTzxxlydyServiceImpl.java
0 → 100644
View file @
3fd69a86
package
com
.
founder
.
interservice
.
service
.
impl
;
import
com.founder.interservice.mapper.cqxz.TbStAsjMapper
;
import
com.founder.interservice.mapper.cqxz.TbTzxxjqTzxxlydyMapper
;
import
com.founder.interservice.model.TbStAsj
;
import
com.founder.interservice.model.TbTzxxjqTzxxlydy
;
import
com.founder.interservice.service.TbTzxxjqTzxxlydyService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
* Created by liuys on 2019/4/24.
*/
@Service
public
class
TbTzxxjqTzxxlydyServiceImpl
implements
TbTzxxjqTzxxlydyService
{
@Autowired
TbTzxxjqTzxxlydyMapper
tzxxlydyMapper
;
@Autowired
TbStAsjMapper
tbStAsjMapper
;
@Override
public
List
<
TbTzxxjqTzxxlydy
>
findTzxxlydyByAsjbh
(
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
)
{
return
tzxxlydyMapper
.
findTzxxlydyByAsjbh
(
tbTzxxjqTzxxlydy
);
}
@Override
public
List
<
TbStAsj
>
findAsjxxByBsh
(
TbTzxxjqTzxxlydy
tbTzxxjqTzxxlydy
)
{
TbTzxxjqTzxxlydy
cxst
=
new
TbTzxxjqTzxxlydy
();
cxst
.
setGjc
(
tbTzxxjqTzxxlydy
.
getGjc
());
List
<
TbTzxxjqTzxxlydy
>
tzxxlydyList
=
tzxxlydyMapper
.
findTzxxlydyByAsjbh
(
cxst
);
StringBuilder
asjbh
=
new
StringBuilder
(
""
);
for
(
TbTzxxjqTzxxlydy
tzxxlydy:
tzxxlydyList
)
{
if
(!
tbTzxxjqTzxxlydy
.
getZjbh
().
equals
(
tzxxlydy
.
getZjbh
())){
asjbh
.
append
(
",'"
+
tzxxlydy
.
getZjbh
()+
"'"
);
}
}
String
asjbhStr
=
asjbh
.
toString
();
if
(
asjbhStr
==
null
||
""
.
equals
(
asjbhStr
)){
return
null
;
}
else
{
return
tbStAsjMapper
.
findAsjxxByAsjbh
(
asjbhStr
.
substring
(
1
));
}
}
}
src/main/resources/application-prod.yml
View file @
3fd69a86
...
@@ -10,6 +10,11 @@ spring:
...
@@ -10,6 +10,11 @@ spring:
username
:
GXZXT_WB
username
:
GXZXT_WB
password
:
GXZXT_WB2018
password
:
GXZXT_WB2018
url
:
jdbc:oracle:thin:@10.154.106.26:1521:XZDB
url
:
jdbc:oracle:thin:@10.154.106.26:1521:XZDB
cqxz
:
driver-class-name
:
oracle.jdbc.driver.OracleDriver
username
:
XZXT
password
:
XzxtPwd#50
url
:
jdbc:oracle:thin:@77.1.24.50:1521:CQXZ
#配置jpa 使其展示sql语句
#配置jpa 使其展示sql语句
jpa
:
jpa
:
show-sql
:
false
show-sql
:
false
\ No newline at end of file
src/main/resources/mybatis/mapper/cqxz/TbStAsjMapper.xml
0 → 100644
View file @
3fd69a86
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.founder.interservice.mapper.cqxz.TbStAsjMapper"
>
<select
id=
"findAsjxxByAsjbh"
parameterType=
"String"
resultType=
"com.founder.interservice.model.TbStAsj"
>
SELECT ASJBH as asjbh,ASJFSSJ_ASJFSKSSJ as asjfssjAsjfskssj,AJMC as ajmc,ASJFSDD_DZMC as asjfsddDzmc,JYAQ as jyaq from TB_ST_ASJ where XXSC_PDBZ='0' and asjbh IN (${_parameter})
</select>
</mapper>
\ No newline at end of file
src/main/resources/mybatis/mapper/cqxz/TbTzxxjqTzxxlydyMapper.xml
0 → 100644
View file @
3fd69a86
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.founder.interservice.mapper.cqxz.TbTzxxjqTzxxlydyMapper"
>
<select
id=
"findTzxxlydyByAsjbh"
parameterType=
"com.founder.interservice.model.TbTzxxjqTzxxlydy"
resultType=
"com.founder.interservice.model.TbTzxxjqTzxxlydy"
>
SELECT bshlx,zjbh,gjc from TB_TZXXJQ_TZXXLXDY where SCBZ=0
<if
test=
"zjbh != null and zjbh != ''"
>
and ZJBH = #{zjbh}
</if>
<if
test=
"gjc != null and gjc != ''"
>
and GJC = #{gjc}
</if>
<if
test=
"bshlx != null and bshlx != ''"
>
and BSHLX = #{bshlx}
</if>
</select>
</mapper>
\ No newline at end of file
src/main/resources/mybatis/mapper/xzxt/RelationMapper.xml
View file @
3fd69a86
...
@@ -70,6 +70,8 @@
...
@@ -70,6 +70,8 @@
r.objecttotype as objecttotype,
r.objecttotype as objecttotype,
r.objecttovalue as objecttovalue,
r.objecttovalue as objecttovalue,
r.timestamp as timestamp,
r.timestamp as timestamp,
r.relativetype as relativetype,
r.relativetypename as relativetypename,
r.first_timestamp as first_timestamp
r.first_timestamp as first_timestamp
from relation r
from relation r
<where>
<where>
...
...
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