Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xyqb-user2
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
head_group
xyqb-user2
Commits
18a71ffe
Commit
18a71ffe
authored
Dec 05, 2022
by
赵浩琳
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
金融调修改手机号接口用原手机号查询用户
parent
b65af786
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
ModifyPhoneRecord.java
.../xyqb/controller/modifyphoneno/req/ModifyPhoneRecord.java
+1
-1
ModifyPhoneNoServiceImpl.java
...roup/xyqb/service/user/impl/ModifyPhoneNoServiceImpl.java
+4
-0
No files found.
src/main/java/cn/quantgroup/xyqb/controller/modifyphoneno/req/ModifyPhoneRecord.java
View file @
18a71ffe
...
...
@@ -12,7 +12,7 @@ import java.io.Serializable;
@Data
public
class
ModifyPhoneRecord
implements
Serializable
{
@NotNull
(
message
=
"用户ID不能为空"
)
//
@NotNull(message = "用户ID不能为空")
private
Long
userId
;
@NotBlank
(
message
=
"原手机号不能为空"
)
...
...
src/main/java/cn/quantgroup/xyqb/service/user/impl/ModifyPhoneNoServiceImpl.java
View file @
18a71ffe
...
...
@@ -49,6 +49,7 @@ import javax.persistence.criteria.Predicate;
import
javax.persistence.criteria.Root
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Objects
;
/**
* Date: 2019/11/4
...
...
@@ -253,6 +254,9 @@ public class ModifyPhoneNoServiceImpl implements IModifyPhoneNoService {
if
(
modifyPhoneRecord
.
getCurPhoneNo
().
equals
(
modifyPhoneRecord
.
getPrevPhoneNo
()))
{
throw
new
DataException
(
"新手机号已存在,不支持更换"
);
}
if
(
Objects
.
isNull
(
modifyPhoneRecord
.
getUserId
())){
throw
new
DataException
(
"用户ID不能为空"
);
}
User
user
=
userService
.
findById
(
modifyPhoneRecord
.
getUserId
());
if
(
user
==
null
)
{
throw
new
DataException
(
"用户不存在"
);
...
...
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