Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
邬吉朋
ops
Commits
ecd4e743
Commit
ecd4e743
authored
Sep 03, 2024
by
wujipeng
Browse files
ssl证书增删改查
parent
8058b868
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/main/java/com/ruzhoukj/sms/controller/ContractController.java
View file @
ecd4e743
...
...
@@ -44,7 +44,7 @@ public class ContractController {
}
@ApiOperation
(
value
=
"删除"
)
@
G
etMapping
(
"/
delete/
{id}"
)
@
Del
et
e
Mapping
(
"/{id}"
)
public
Result
deleteContract
(
@PathVariable
String
id
)
{
return
Result
.
success
(
contractService
.
deleteContract
(
id
));
}
...
...
src/main/java/com/ruzhoukj/sms/controller/SSLController.java
View file @
ecd4e743
package
com.ruzhoukj.sms.controller
;
import
com.ruzhoukj.sms.common.PageResponse
;
import
com.ruzhoukj.sms.common.Result
;
import
com.ruzhoukj.sms.pojo.dto.SSLDTO
;
import
com.ruzhoukj.sms.pojo.vo.SSLVO
;
import
com.ruzhoukj.sms.service.SSLService
;
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
io.swagger.annotations.ApiOperation
;
import
org.springframework.web.bind.annotation.*
;
import
javax.annotation.Resource
;
import
java.util.List
;
...
...
@@ -24,9 +23,28 @@ public class SSLController {
@Resource
private
SSLService
sslService
;
@ApiOperation
(
"分页查询"
)
@PostMapping
(
"/page"
)
public
PageResponse
<
List
<
SSLVO
>>
page
(
@RequestBody
SSLDTO
ssldto
)
{
List
<
SSLVO
>
list
=
sslService
.
pageSSL
(
ssldto
);
return
PageResponse
.
success
(
list
.
size
(),
list
);
}
@ApiOperation
(
"新增或修改"
)
@PostMapping
(
"/saveOrUpdate"
)
public
Result
saveSSL
(
@RequestBody
SSLDTO
ssldto
)
{
return
Result
.
success
(
sslService
.
saveOrUpdate
(
ssldto
));
}
@ApiOperation
(
"删除"
)
@DeleteMapping
(
"/{id}"
)
public
Result
saveSSL
(
@PathVariable
String
id
)
{
return
Result
.
success
(
sslService
.
removeById
(
id
));
}
@ApiOperation
(
"查询详情"
)
@GetMapping
(
"/{id}"
)
public
Result
getSSL
(
@PathVariable
String
id
)
{
return
Result
.
success
(
sslService
.
getById
(
id
));
}
}
src/main/resources/com/ruzhoukj/sms/dao/SSLDao.xml
View file @
ecd4e743
...
...
@@ -30,5 +30,6 @@
name,
time
from `ssl`
order by time asc
</select>
</mapper>
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