Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
projectArtifacture
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
yangzhaojun
projectArtifacture
Commits
9f5914ec
Commit
9f5914ec
authored
Jan 16, 2018
by
李丛阳
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
逻辑删除
parent
a8bfaf25
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletion
+2
-1
controller.ftl
src/main/resources/templates/codeftl/controller.ftl
+1
-1
serviceimpl.ftl
src/main/resources/templates/codeftl/serviceimpl.ftl
+1
-0
No files found.
src/main/resources/templates/codeftl/controller.ftl
View file @
9f5914ec
...
...
@@ -38,7 +38,7 @@ public class ${table.entityName}Controller extends PaginationController<${table.
@
ApiOperation
(
value
=
"添加${table.tableRemark!}"
,
notes
=
"添加${table.tableRemark!}"
)
//@
ApiImplicitParams
({@
ApiImplicitParam
(
name
=
"businessId"
,
value
=
"businessId"
,
required
=
false
,
dataType
=
"varchar"
)})
@
PostMapping
@
PostMapping
(
value
=
"/add"
)
public
Result
add
(@
Valid
${
table
.
entityName
}
${
table
.
entityName
?
uncap_first
},
BindingResult
bindingResult
)
{
if
(
bindingResult
.
hasErrors
())
{
throw
new
ServiceException
(
ResultServiceEnums
.
PARAMETER_ERROR
.
getCode
(),
...
...
src/main/resources/templates/codeftl/serviceimpl.ftl
View file @
9f5914ec
...
...
@@ -56,6 +56,7 @@ public class ${table.entityName}ServiceImpl implements ${table.entityName}Servic
@
Override
public
PersistModel
remove
(${
table
.
entityName
}
${
table
.
entityName
?
uncap_first
}){
UserUtil
.
setCurrentMergeOperation
(${
table
.
entityName
?
uncap_first
});
${
table
.
entityName
?
uncap_first
}.
setDeleted
();
int
line
=
${
table
.
entityName
?
uncap_first
}
Repository
.
logicalDelete
(${
table
.
entityName
?
uncap_first
});
log
.
info
(
UserUtil
.
getUserInfoProp
(${
table
.
entityName
?
uncap_first
}.
getToken
(),
UserUtil
.
USER_USERNAME
)+
"逻辑删除了ID为"
+
${
table
.
entityName
?
uncap_first
}.
getBusinessId
()+
"的信息"
);
...
...
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