Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dmhub-plugin
Project
Project
Details
Activity
Releases
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
qinxunjia
dmhub-plugin
Commits
528ba3c0
Commit
528ba3c0
authored
Apr 21, 2020
by
danzhongqin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
定义DTO
parent
3a7c4917
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
47 additions
and
14 deletions
+47
-14
BizController.java
src/main/java/com/jz/sms/api/BizController.java
+10
-3
SendService.java
src/main/java/com/jz/sms/chuanlan/SendService.java
+3
-3
SendServiceImpl.java
src/main/java/com/jz/sms/chuanlan/impl/SendServiceImpl.java
+18
-8
XfaceClTemplateRequestDTO.java
src/main/java/com/jz/sms/dto/XfaceClTemplateRequestDTO.java
+4
-0
XfaceClTemplateResponseDTO.java
src/main/java/com/jz/sms/dto/XfaceClTemplateResponseDTO.java
+4
-0
XfaceDmHubTemplateRequestDTO.java
...ain/java/com/jz/sms/dto/XfaceDmHubTemplateRequestDTO.java
+4
-0
XfaceDmHubTemplateResponseDTO.java
...in/java/com/jz/sms/dto/XfaceDmHubTemplateResponseDTO.java
+4
-0
No files found.
src/main/java/com/jz/sms/api/BizController.java
View file @
528ba3c0
package
com
.
jz
.
sms
.
api
;
package
com
.
jz
.
sms
.
api
;
import
com.jz.sms.chuanlan.SendService
;
import
com.jz.sms.dto.XfaceDmHubTemplateRequestDTO
;
import
com.jz.sms.dto.XfaceDmHubTemplateResponseDTO
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
...
@@ -7,6 +11,9 @@ import org.springframework.web.bind.annotation.RestController;
...
@@ -7,6 +11,9 @@ import org.springframework.web.bind.annotation.RestController;
@RequestMapping
(
"test"
)
@RequestMapping
(
"test"
)
public
class
BizController
{
public
class
BizController
{
@Autowired
private
SendService
service
;
@RequestMapping
(
"index"
)
@RequestMapping
(
"index"
)
public
String
index
()
{
public
String
index
()
{
...
@@ -20,9 +27,9 @@ public class BizController {
...
@@ -20,9 +27,9 @@ public class BizController {
* @return
* @return
*/
*/
@RequestMapping
(
"/sms/template"
)
@RequestMapping
(
"/sms/template"
)
public
String
template
(
)
{
public
XfaceDmHubTemplateResponseDTO
template
(
XfaceDmHubTemplateRequestDTO
requestDTO
)
{
XfaceDmHubTemplateResponseDTO
responseDTO
=
service
.
send
(
requestDTO
);
return
"success"
;
return
responseDTO
;
}
}
...
...
src/main/java/com/jz/sms/chuanlan/SendService.java
View file @
528ba3c0
package
com
.
jz
.
sms
.
chuanlan
;
package
com
.
jz
.
sms
.
chuanlan
;
import
java.util.Map
;
import
com.jz.sms.dto.XfaceDmHubTemplateRequestDTO
;
import
com.jz.sms.dto.XfaceDmHubTemplateResponseDTO
;
public
interface
SendService
{
public
interface
SendService
{
XfaceDmHubTemplateResponseDTO
send
(
XfaceDmHubTemplateRequestDTO
requestDTO
);
Map
<
String
,
Object
>
send
(
Map
<
String
,
Object
>
params
);
}
}
src/main/java/com/jz/sms/chuanlan/impl/SendServiceImpl.java
View file @
528ba3c0
...
@@ -2,6 +2,10 @@ package com.jz.sms.chuanlan.impl;
...
@@ -2,6 +2,10 @@ package com.jz.sms.chuanlan.impl;
import
com.jz.sms.chuanlan.SendService
;
import
com.jz.sms.chuanlan.SendService
;
import
com.jz.sms.dto.XfaceClTemplateRequestDTO
;
import
com.jz.sms.dto.XfaceClTemplateResponseDTO
;
import
com.jz.sms.dto.XfaceDmHubTemplateRequestDTO
;
import
com.jz.sms.dto.XfaceDmHubTemplateResponseDTO
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -11,13 +15,19 @@ public class SendServiceImpl implements SendService {
...
@@ -11,13 +15,19 @@ public class SendServiceImpl implements SendService {
@Override
@Override
public
Map
<
String
,
Object
>
send
(
Map
<
String
,
Object
>
params
)
{
public
XfaceDmHubTemplateResponseDTO
send
(
XfaceDmHubTemplateRequestDTO
requestDTO
)
{
/**
* 调用创蓝的业务逻辑.....
* requestDTO.getXXX....
*/
XfaceClTemplateRequestDTO
clRequestDto
=
new
XfaceClTemplateRequestDTO
();
XfaceClTemplateResponseDTO
clResponseDTO
=
new
XfaceClTemplateResponseDTO
();
return
null
;
/**
* 调用结果包装到DM Hub Response中
*/
XfaceDmHubTemplateResponseDTO
responseDTO
=
new
XfaceDmHubTemplateResponseDTO
();
return
responseDTO
;
}
}
}
}
src/main/java/com/jz/sms/dto/XfaceClTemplateRequestDTO.java
0 → 100644
View file @
528ba3c0
package
com
.
jz
.
sms
.
dto
;
public
class
XfaceClTemplateRequestDTO
{
}
src/main/java/com/jz/sms/dto/XfaceClTemplateResponseDTO.java
0 → 100644
View file @
528ba3c0
package
com
.
jz
.
sms
.
dto
;
public
class
XfaceClTemplateResponseDTO
{
}
src/main/java/com/jz/sms/dto/XfaceDmHubTemplateRequestDTO.java
0 → 100644
View file @
528ba3c0
package
com
.
jz
.
sms
.
dto
;
public
class
XfaceDmHubTemplateRequestDTO
{
}
src/main/java/com/jz/sms/dto/XfaceDmHubTemplateResponseDTO.java
0 → 100644
View file @
528ba3c0
package
com
.
jz
.
sms
.
dto
;
public
class
XfaceDmHubTemplateResponseDTO
{
}
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