Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
map-parent
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
常超
map-parent
Commits
2e6cb56c
Commit
2e6cb56c
authored
Apr 22, 2021
by
chentian
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
9fc95847
8c66e037
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
302 additions
and
0 deletions
+302
-0
common/common_utils/src/main/java/com/founder/commonutils/peopleEntity/PeopleInfo.java
+33
-0
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/controller/PeopleContoller.java
+42
-0
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/mapper/PeopleInfoMapper.java
+7
-0
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/mapper/xml/PeopleInfoMapper.xml
+6
-0
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/service/PeopleService.java
+8
-0
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/service/impl/PeopleServiceImpl.java
+206
-0
No files found.
common/common_utils/src/main/java/com/founder/commonutils/peopleEntity/PeopleInfo.java
0 → 100644
View file @
2e6cb56c
package
com
.
founder
.
commonutils
.
peopleEntity
;
import
java.util.List
;
public
class
PeopleInfo
{
private
String
objectType
;
/*01:车牌号码 03:证件号码 04:手机号码 05:IMSI 06:QQ 07:微信 08:IMEI*/
private
String
objectValue
;
private
List
<
PeopleInfo
>
children
;
public
String
getObjectType
()
{
return
objectType
;
}
public
void
setObjectType
(
String
objectType
)
{
this
.
objectType
=
objectType
;
}
public
String
getObjectValue
()
{
return
objectValue
;
}
public
void
setObjectValue
(
String
objectValue
)
{
this
.
objectValue
=
objectValue
;
}
public
List
<
PeopleInfo
>
getChildren
()
{
return
children
;
}
public
void
setChildren
(
List
<
PeopleInfo
>
children
)
{
this
.
children
=
children
;
}
}
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/controller/PeopleContoller.java
0 → 100644
View file @
2e6cb56c
package
com
.
founder
.
peopleapi
.
controller
;
import
com.founder.commonutils.publicEntity.MapRestResult
;
import
com.founder.peopleapi.service.PeopleService
;
import
com.founder.servicebase.logs.OperLog
;
import
com.founder.servicebase.logs.OperationType
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* <p>
* 技侦接口管理 前端控制器
* </p>
*
* @author liuyaxin
* @since 2021-04-21
*/
@Api
(
description
=
"接口管理"
)
@RestController
@RequestMapping
(
"/people"
)
public
class
PeopleContoller
{
@Autowired
private
PeopleService
peopleService
;
@ApiOperation
(
value
=
"虚实身份信息"
)
@OperLog
(
message
=
"虚实身份信息"
,
operation
=
OperationType
.
QUERY
)
@PostMapping
(
"/getXsSfXx"
)
public
MapRestResult
getXsSfXx
(
@ApiParam
(
name
=
"objectValue"
,
value
=
"标识号值"
,
required
=
true
)
@RequestParam
String
objectValue
,
@ApiParam
(
name
=
"objectType"
,
value
=
"标识号类型"
,
required
=
true
)
@RequestParam
String
objectType
)
{
return
peopleService
.
getXsSfXx
(
objectType
,
objectValue
);
}
}
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/mapper/PeopleInfoMapper.java
0 → 100644
View file @
2e6cb56c
package
com
.
founder
.
peopleapi
.
mapper
;
import
org.apache.ibatis.annotations.Mapper
;
@Mapper
public
interface
PeopleInfoMapper
{
}
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/mapper/xml/PeopleInfoMapper.xml
0 → 100644
View file @
2e6cb56c
<?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.peopleapi.mapper.PeopleInfoMapper"
>
</mapper>
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/service/PeopleService.java
0 → 100644
View file @
2e6cb56c
package
com
.
founder
.
peopleapi
.
service
;
import
com.founder.commonutils.publicEntity.MapRestResult
;
public
interface
PeopleService
{
MapRestResult
getXsSfXx
(
String
objectType
,
String
objectValue
);
}
serviceapi/peopleapi/src/main/java/com/founder/peopleapi/service/impl/PeopleServiceImpl.java
0 → 100644
View file @
2e6cb56c
package
com
.
founder
.
peopleapi
.
service
.
impl
;
import
com.alibaba.fastjson.JSONObject
;
import
com.founder.commonutils.peopleEntity.PeopleInfo
;
import
com.founder.commonutils.publicEntity.MapRestResult
;
import
com.founder.peopleapi.service.PeopleService
;
import
org.apache.commons.lang.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.http.HttpEntity
;
import
org.springframework.stereotype.Service
;
import
org.springframework.web.client.RestTemplate
;
import
java.util.ArrayList
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
@Service
public
class
PeopleServiceImpl
implements
PeopleService
{
@Autowired
private
RestTemplate
restTemplate
;
/*objectType 01:车牌号 03:证件号 04:手机号 05:IMSI 06:QQ 07:微信 08:IMEI*/
@Override
public
MapRestResult
getXsSfXx
(
String
objectType
,
String
objectValue
)
{
List
resultList
=
new
ArrayList
();
if
(
"01"
.
equals
(
objectType
))
{
List
<
PeopleInfo
>
czList
=
getCarInfo
(
objectType
,
objectValue
);
for
(
PeopleInfo
peopleInfo
:
czList
)
{
if
(
"03"
.
equals
(
peopleInfo
.
getObjectType
()))
{
PeopleInfo
peopleInfo1
=
xsxxByZjhm
(
peopleInfo
.
getObjectType
(),
peopleInfo
.
getObjectValue
());
resultList
.
add
(
peopleInfo1
);
}
}
}
else
if
(
"03"
.
equals
(
objectType
))
{
PeopleInfo
peopleInfo
=
xsxxByZjhm
(
objectType
,
objectValue
);
resultList
.
add
(
peopleInfo
);
}
else
if
(
"04"
.
equals
(
objectType
))
{
List
<
PeopleInfo
>
czList
=
getSjSmInfo
(
objectType
,
objectValue
);
for
(
PeopleInfo
peopleInfo
:
czList
)
{
if
(
"03"
.
equals
(
peopleInfo
.
getObjectType
()))
{
PeopleInfo
peopleInfo1
=
xsxxByZjhm
(
peopleInfo
.
getObjectType
(),
peopleInfo
.
getObjectValue
());
resultList
.
add
(
peopleInfo1
);
}
}
}
else
{
return
MapRestResult
.
error
(
"无法查询此标识号类型"
);
}
return
MapRestResult
.
build
(
200
,
"成功获取虚实身份信息!"
,
resultList
);
}
/*通过证件号获取各类信息*/
public
PeopleInfo
xsxxByZjhm
(
String
objectType
,
String
objectValue
)
{
PeopleInfo
peopleInfo
=
new
PeopleInfo
();
peopleInfo
.
setObjectType
(
objectType
);
peopleInfo
.
setObjectValue
(
objectValue
);
List
<
PeopleInfo
>
carInfo
=
getCarInfo
(
objectType
,
objectValue
);
List
xssfxxList
=
new
ArrayList
();
List
<
PeopleInfo
>
jzInfo
=
getSjSmInfo
(
objectType
,
objectValue
);
for
(
PeopleInfo
peopleInfo1
:
jzInfo
)
{
if
(
"04"
.
equals
(
peopleInfo1
.
getObjectType
()))
{
List
list
=
getXnXxInfo
(
peopleInfo1
.
getObjectType
(),
peopleInfo1
.
getObjectValue
());
peopleInfo1
.
setChildren
(
list
);
xssfxxList
.
add
(
peopleInfo1
);
}
}
List
childrenList
=
new
ArrayList
();
childrenList
.
addAll
(
jzInfo
);
childrenList
.
addAll
(
carInfo
);
peopleInfo
.
setChildren
(
childrenList
);
return
peopleInfo
;
}
/*标识号类型bshlx:01车辆;02身份证号;03手机号;04IMEI;05IMSI;06QQ;07微信*/
/*获取车主信息*/
public
List
getCarInfo
(
String
objectType
,
String
objectValue
)
{
List
childrenList
=
new
ArrayList
();
HttpEntity
<
JSONObject
>
jsonObject
=
restTemplate
.
getForEntity
(
"http://26.3.13.120:8501/common/getQgCarXxByHm?hphm="
+
objectValue
,
JSONObject
.
class
);
if
(
StringUtils
.
isNotEmpty
(
String
.
valueOf
(
jsonObject
.
getBody
())))
{
if
(
jsonObject
.
getBody
().
containsKey
(
"data"
))
{
LinkedHashMap
resultJson
=
(
LinkedHashMap
)
jsonObject
.
getBody
().
get
(
"data"
);
//获取返回的数据结果
System
.
out
.
println
(
resultJson
.
toString
());
List
<
LinkedHashMap
>
array
=
(
List
<
LinkedHashMap
>)
resultJson
.
get
(
"rows"
);
for
(
int
i
=
0
;
i
<
array
.
size
();
i
++)
{
LinkedHashMap
object
=
array
.
get
(
i
);
String
zjhm
=
(
String
)
object
.
get
(
"sfzh"
);
String
cphm
=
(
String
)
object
.
get
(
"hphm"
);
PeopleInfo
peopleInfo
=
new
PeopleInfo
();
if
(
"01"
.
equals
(
objectType
))
{
peopleInfo
.
setObjectType
(
"03"
);
peopleInfo
.
setObjectValue
(
zjhm
);
childrenList
.
add
(
peopleInfo
);
}
else
if
(
"03"
.
equals
(
objectType
))
{
peopleInfo
.
setObjectType
(
"01"
);
peopleInfo
.
setObjectValue
(
cphm
);
childrenList
.
add
(
peopleInfo
);
}
}
}
}
return
childrenList
;
}
/*手机实名*/
public
List
getSjSmInfo
(
String
objectType
,
String
objectValue
)
{
List
childrenList
=
new
ArrayList
();
String
url
=
null
;
if
(
"03"
.
equals
(
objectType
))
{
url
=
"http://26.3.13.120:8501/nmsj/getMySfSjGl?zjhm="
+
objectValue
;
}
else
if
(
"04"
.
equals
(
objectType
))
{
url
=
"http://26.3.13.120:8501/nmsj/getMySfSjGl?sjhm="
+
objectValue
;
}
HttpEntity
<
JSONObject
>
jsonObject
=
restTemplate
.
getForEntity
(
url
,
JSONObject
.
class
);
if
(
StringUtils
.
isNotEmpty
(
String
.
valueOf
(
jsonObject
.
getBody
())))
{
if
(
jsonObject
.
getBody
().
containsKey
(
"data"
))
{
LinkedHashMap
resultJson
=
(
LinkedHashMap
)
jsonObject
.
getBody
().
get
(
"data"
);
//获取返回的数据结果
List
<
LinkedHashMap
>
array
=
(
List
<
LinkedHashMap
>)
resultJson
.
get
(
"rows"
);
System
.
out
.
println
(
array
.
toString
());
for
(
int
i
=
0
;
i
<
array
.
size
();
i
++)
{
LinkedHashMap
object
=
array
.
get
(
i
);
String
zjhm
=
(
String
)
object
.
get
(
"zjhm"
);
String
bshxx
=
(
String
)
object
.
get
(
"bshxx"
);
String
bshlx
=
(
String
)
object
.
get
(
"bshlx"
);
PeopleInfo
peopleInfo
=
new
PeopleInfo
();
if
(
"03"
.
equals
(
objectType
))
{
/*该03为证件号码*/
if
(
"03"
.
equals
(
bshlx
))
{
/*此03为手机号码*/
peopleInfo
.
setObjectType
(
"04"
);
peopleInfo
.
setObjectValue
(
bshxx
);
childrenList
.
add
(
peopleInfo
);
}
}
else
if
(
"04"
.
equals
(
objectType
))
{
/*此04为手机号码*/
peopleInfo
.
setObjectType
(
"03"
);
peopleInfo
.
setObjectValue
(
zjhm
);
childrenList
.
add
(
peopleInfo
);
}
}
}
}
return
childrenList
;
}
/*手机虚拟信息*/
public
List
getXnXxInfo
(
String
objectType
,
String
objectValue
)
{
/*手机信息目录*/
List
childrenList
=
new
ArrayList
();
HttpEntity
<
JSONObject
>
jsonObject
=
restTemplate
.
getForEntity
(
"http://26.3.13.120:8501/nmsj/getMyWxQqZcXxFw?xnhm="
+
objectValue
,
JSONObject
.
class
);
if
(
StringUtils
.
isNotEmpty
(
String
.
valueOf
(
jsonObject
.
getBody
())))
{
if
(
jsonObject
.
getBody
().
containsKey
(
"data"
))
{
LinkedHashMap
resultJson
=
(
LinkedHashMap
)
jsonObject
.
getBody
().
get
(
"data"
);
//获取返回的数据结果
List
<
LinkedHashMap
>
array
=
(
List
<
LinkedHashMap
>)
resultJson
.
get
(
"rows"
);
for
(
int
i
=
0
;
i
<
array
.
size
();
i
++)
{
LinkedHashMap
object
=
array
.
get
(
i
);
String
bshxx
=
(
String
)
object
.
get
(
"bshxx"
);
String
bshlx
=
(
String
)
object
.
get
(
"bshlx"
);
PeopleInfo
peopleInfo1
=
new
PeopleInfo
();
if
(
"06"
.
equals
(
bshlx
))
{
peopleInfo1
.
setObjectType
(
"06"
);
peopleInfo1
.
setObjectValue
(
bshxx
);
childrenList
.
add
(
peopleInfo1
);
}
else
if
(
"07"
.
equals
(
bshlx
))
{
peopleInfo1
.
setObjectType
(
"07"
);
peopleInfo1
.
setObjectValue
(
bshxx
);
childrenList
.
add
(
peopleInfo1
);
}
}
}
}
HttpEntity
<
JSONObject
>
jsonObject2
=
restTemplate
.
getForEntity
(
"http://26.3.13.120:8501/nmsj/getMySjSmBsh?sjhm="
+
objectValue
,
JSONObject
.
class
);
if
(
StringUtils
.
isNotEmpty
(
String
.
valueOf
(
jsonObject2
.
getBody
())))
{
if
(
jsonObject2
.
getBody
().
containsKey
(
"data"
))
{
LinkedHashMap
resultJson
=
(
LinkedHashMap
)
jsonObject2
.
getBody
().
get
(
"data"
);
//获取返回的数据结果
List
<
LinkedHashMap
>
array
=
(
List
<
LinkedHashMap
>)
resultJson
.
get
(
"rows"
);
System
.
out
.
println
(
array
);
for
(
int
i
=
0
;
i
<
array
.
size
();
i
++)
{
LinkedHashMap
object
=
array
.
get
(
i
);
String
bshxx
=
(
String
)
object
.
get
(
"bshxx"
);
String
bshlx
=
(
String
)
object
.
get
(
"bshlx"
);
PeopleInfo
peopleInfo1
=
new
PeopleInfo
();
if
(
"04"
.
equals
(
bshlx
))
{
peopleInfo1
.
setObjectType
(
"08"
);
peopleInfo1
.
setObjectValue
(
bshxx
);
childrenList
.
add
(
peopleInfo1
);
}
else
if
(
"05"
.
equals
(
bshlx
))
{
peopleInfo1
.
setObjectType
(
"05"
);
peopleInfo1
.
setObjectValue
(
bshxx
);
childrenList
.
add
(
peopleInfo1
);
}
}
}
}
return
childrenList
;
}
}
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