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
8e233941
Commit
8e233941
authored
Apr 27, 2023
by
yangyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
标采接口服务管理(重庆)
parent
0e85000e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
5 deletions
+31
-5
service/publicapi/src/main/java/com/founder/publicapi/PublicapiApplication.java
+12
-0
service/publicapi/src/main/java/com/founder/publicapi/controller/cqService/CqController.java
+19
-5
No files found.
service/publicapi/src/main/java/com/founder/publicapi/PublicapiApplication.java
View file @
8e233941
...
...
@@ -5,7 +5,10 @@ import org.mybatis.spring.annotation.MapperScan;
import
org.springframework.boot.SpringApplication
;
import
org.springframework.boot.autoconfigure.SpringBootApplication
;
import
org.springframework.context.ConfigurableApplicationContext
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.ComponentScan
;
import
org.springframework.http.client.SimpleClientHttpRequestFactory
;
import
org.springframework.web.client.RestTemplate
;
@SpringBootApplication
...
...
@@ -20,4 +23,13 @@ public class PublicapiApplication {
SpringUtil
.
applicationContext
=
applicationContext
;
}
@Bean
public
RestTemplate
restTemplate
(){
SimpleClientHttpRequestFactory
factory
=
new
SimpleClientHttpRequestFactory
();
factory
.
setConnectTimeout
(
100000
);
factory
.
setReadTimeout
(
100000
);
RestTemplate
restTemplate
=
new
RestTemplate
(
factory
);
return
restTemplate
;
}
}
service/publicapi/src/main/java/com/founder/publicapi/controller/cqService/CqController.java
View file @
8e233941
...
...
@@ -15,10 +15,9 @@ import io.swagger.annotations.Api;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.client.RestTemplate
;
import
org.springframework.web.multipart.MultipartFile
;
import
javax.servlet.http.HttpServletResponse
;
...
...
@@ -36,7 +35,8 @@ public class CqController {
private
String
xdhAjUrl
;
@Autowired
TbStAsjqgMapper
tbStAsjqgMapper
;
@Autowired
RestTemplate
restTemplate
;
@OperLog
(
message
=
"模板手机号导入"
,
operation
=
OperationType
.
QUERY
)
@PostMapping
(
"import"
)
@ApiOperation
(
value
=
"模板手机号导入"
,
notes
=
"传入excel"
)
...
...
@@ -1355,4 +1355,18 @@ public class CqController {
return
resultCar
;
}
// ZJHM R-500000000000-00000728
@OperLog
(
message
=
"标采人像查询接口服务"
,
operation
=
OperationType
.
QUERY
)
@GetMapping
(
"bcrxcxRequest"
)
@ApiOperation
(
value
=
"标采人像查询接口服务"
,
notes
=
"标采人像查询接口服务"
)
public
JSONObject
bcrxcxRequest
(
@RequestParam
String
sfzh
)
{
ResponseEntity
<
JSONObject
>
result
=
null
;
try
{
result
=
restTemplate
.
getForEntity
(
"http://77.1.24.41/cj/public/personPhotoes?token=4177E0BF686742BA84B04C8D1B6A97E7&sfzh="
+
sfzh
,
JSONObject
.
class
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
return
result
.
getBody
();
}
}
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