Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mybatisplus-inverse_swagger
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
fxkc_tools
mybatisplus-inverse_swagger
Commits
2d2c04c4
Commit
2d2c04c4
authored
Apr 26, 2022
by
xiemouren
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整控制层模板
parent
106fb729
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
0 deletions
+17
-0
src/main/resources/templates/my.controller.java.ftl
src/main/resources/templates/my.controller.java.ftl
+17
-0
No files found.
src/main/resources/templates/my.controller.java.ftl
View file @
2d2c04c4
...
...
@@ -2,6 +2,8 @@ package ${package.Controller};
import
org
.
springframework
.
web
.
bind
.
annotation
.
RequestMapping
;
import
org
.
springframework
.
web
.
bind
.
annotation
.
PostMapping
;
import
org
.
springframework
.
web
.
bind
.
annotation
.
GetMapping
;
<#
if
restControllerStyle
>
import
org
.
springframework
.
web
.
bind
.
annotation
.
RestController
;
...
...
@@ -11,6 +13,8 @@ import org.springframework.stereotype.Controller;
<#
if
superControllerClassPackage
??>
import
${
superControllerClassPackage
};
</#
if
>
import
io
.
swagger
.
annotations
.
Api
;
import
io
.
swagger
.
annotations
.
ApiOperation
;
/**
*
${
table
.
comment
!} 控制层
...
...
@@ -18,6 +22,7 @@ import ${superControllerClassPackage};
*
@
author
${
author
}
*
@
since
${
date
}
*/
@
Api
(
value
=
"${table.comment!}"
,
tags
=
{
"${table.comment!}"
})
<#
if
restControllerStyle
>
@
RestController
<#
else
>
...
...
@@ -33,5 +38,17 @@ public class ${table.controllerName} extends ${superControllerClass} {
public
class
${
table
.
controllerName
}
{
</#
if
>
@
ApiOperation
(
"DemoPost接口"
)
@
PostMapping
(
"/post"
)
public
void
post
()
{
}
@
ApiOperation
(
"DemoGet接口"
)
@
GetMapping
(
"/get"
)
public
void
get
()
{
}
}
</#
if
>
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