Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cash-loan-flow-boss
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
QG
cash-loan-flow-boss
Commits
4db9b507
Commit
4db9b507
authored
Dec 08, 2020
by
suntao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加删除用户功能
parent
7687f7aa
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
2 deletions
+24
-2
UserController.java
.../cashloanflowboss/api/user/controller/UserController.java
+12
-0
UserService.java
...tgroup/cashloanflowboss/api/user/service/UserService.java
+6
-2
UserServiceImpl.java
...up/cashloanflowboss/api/user/service/UserServiceImpl.java
+6
-0
No files found.
src/main/java/cn/quantgroup/cashloanflowboss/api/user/controller/UserController.java
View file @
4db9b507
...
...
@@ -89,6 +89,18 @@ public class UserController {
return
this
.
userService
.
disableUser
(
id
);
}
/**
* s删除用户
*
* @param id 用户ID
* @return
*/
@DeleteMapping
(
"/delete"
)
@Security
(
authorityId
=
"User.delete"
)
public
Boolean
deleteUser
(
@RequestParam
@Valid
@NotNull
(
message
=
"无效的用户ID"
)
Long
id
)
{
return
this
.
userService
.
deleteUser
(
id
);
}
/**
* 移除用户
*
...
...
src/main/java/cn/quantgroup/cashloanflowboss/api/user/service/UserService.java
View file @
4db9b507
...
...
@@ -53,6 +53,10 @@ public interface UserService {
Result
<
Boolean
>
updatePassword
(
UpdatePasswordParam
updatePasswordParam
);
/**
* 删除用户
* @param id
* @return
*/
Boolean
deleteUser
(
Long
id
);
}
src/main/java/cn/quantgroup/cashloanflowboss/api/user/service/UserServiceImpl.java
View file @
4db9b507
...
...
@@ -372,4 +372,10 @@ public class UserServiceImpl implements UserService {
userRepository
.
save
(
user
);
return
Result
.
buildSuccess
(
true
);
}
@Override
public
Boolean
deleteUser
(
Long
id
)
{
userRepository
.
delete
(
id
);
return
true
;
}
}
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