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
81b95099
Commit
81b95099
authored
Sep 25, 2019
by
王俊权
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加操作日志(清除用户数据)
parent
a7a3715a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
45 deletions
+10
-45
OrderServiceImpl.java
.../cashloanflowboss/api/order/service/OrderServiceImpl.java
+1
-1
UserController.java
.../cashloanflowboss/api/user/controller/UserController.java
+3
-13
XyqbUserService.java
...up/cashloanflowboss/spi/user/service/XyqbUserService.java
+1
-7
XyqbUserServiceImpl.java
...ashloanflowboss/spi/user/service/XyqbUserServiceImpl.java
+5
-24
No files found.
src/main/java/cn/quantgroup/cashloanflowboss/api/order/service/OrderServiceImpl.java
View file @
81b95099
...
@@ -557,7 +557,7 @@ public class OrderServiceImpl implements OrderService{
...
@@ -557,7 +557,7 @@ public class OrderServiceImpl implements OrderService{
data
.
put
(
"flowNo"
,
UUID
.
randomUUID
());
data
.
put
(
"flowNo"
,
UUID
.
randomUUID
());
String
id
=
clothoCenterService
.
cancelAfterLoan
(
data
);
String
id
=
clothoCenterService
.
cancelAfterLoan
(
data
);
return
new
Tuple
<>(
fals
e
,
"贷后关单成功"
);
return
new
Tuple
<>(
tru
e
,
"贷后关单成功"
);
}
}
/**
/**
...
...
src/main/java/cn/quantgroup/cashloanflowboss/api/user/controller/UserController.java
View file @
81b95099
...
@@ -111,17 +111,6 @@ public class UserController {
...
@@ -111,17 +111,6 @@ public class UserController {
return
Result
.
buildSuccess
(
userService
.
getUserDetailInfo
());
return
Result
.
buildSuccess
(
userService
.
getUserDetailInfo
());
}
}
/**
* 清除用户信息
*
* @param id 用户ID
* @return
*/
@PutMapping
(
"/clean"
)
public
Boolean
cleanUser
(
@RequestParam
@Valid
@NotEmpty
(
message
=
"无效的用户ID"
)
String
phoneNo
)
{
return
this
.
xyqbUserService
.
cleanUserExtInfo
(
phoneNo
);
}
/**
/**
* 清除用户活跃订单
* 清除用户活跃订单
*
*
...
@@ -134,14 +123,15 @@ public class UserController {
...
@@ -134,14 +123,15 @@ public class UserController {
}
}
/**
/**
*
删除订单
*
清除用户信息
*
*
* @param mobile 用户ID
* @param mobile 用户ID
* @return
* @return
*/
*/
@PutMapping
(
"/info/clean"
)
@PutMapping
(
"/info/clean"
)
public
Boolean
deleteByUserId
(
@RequestParam
@Valid
@NotEmpty
(
message
=
"无效的用户手机号"
)
String
mobile
)
{
public
Boolean
deleteByUserId
(
@RequestParam
@Valid
@NotEmpty
(
message
=
"无效的用户手机号"
)
String
mobile
)
{
return
this
.
xyqbUserService
.
deleteByUserId
(
mobile
);
Tuple
<
Boolean
,
String
>
result
=
this
.
xyqbUserService
.
deleteByUserId
(
mobile
);
return
result
.
getKey
();
}
}
}
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/user/service/XyqbUserService.java
View file @
81b95099
...
@@ -52,12 +52,6 @@ public interface XyqbUserService {
...
@@ -52,12 +52,6 @@ public interface XyqbUserService {
*/
*/
UserInfo
findUserByUuid
(
String
uuid
);
UserInfo
findUserByUuid
(
String
uuid
);
/**
* 清除用户信息
* @param phoneNo
* @return
*/
Boolean
cleanUserExtInfo
(
String
phoneNo
);
/**
/**
* 清除用户活跃订单
* 清除用户活跃订单
...
@@ -69,5 +63,5 @@ public interface XyqbUserService {
...
@@ -69,5 +63,5 @@ public interface XyqbUserService {
/**
/**
* 删除记录
* 删除记录
*/
*/
Boolean
deleteByUserId
(
String
phoneNo
);
Tuple
<
Boolean
,
String
>
deleteByUserId
(
String
phoneNo
);
}
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/user/service/XyqbUserServiceImpl.java
View file @
81b95099
...
@@ -141,26 +141,6 @@ public class XyqbUserServiceImpl implements XyqbUserService {
...
@@ -141,26 +141,6 @@ public class XyqbUserServiceImpl implements XyqbUserService {
return
userInfo
.
getData
();
return
userInfo
.
getData
();
}
}
/**
* 清除用户信息
*/
@Override
public
Boolean
cleanUserExtInfo
(
String
phoneNo
)
{
if
(
StringUtils
.
isEmpty
(
phoneNo
))
{
return
false
;
}
UserSysResult
<
XUser
>
user
=
userSysService
.
getService
().
findUserByPhoneNo
(
phoneNo
);
if
(
Objects
.
isNull
(
user
)
||
Objects
.
isNull
(
user
.
getData
()))
{
return
false
;
}
Long
user_id
=
user
.
getData
().
getId
();
UserSysResult
<
Boolean
>
result
=
userSysService
.
getService
().
disableUser
(
user_id
);
UserSysResult
<
XUserExtInfo
>
userExtInfo
=
userSysService
.
getService
().
updateUserExtInfo
(
user_id
,
IncomeEnum
.
UNKNOWN
,
IncomeRangeEnum
.
UNKNOWN
,
null
,
null
,
null
,
null
,
null
,
null
,
null
);
if
(!
userExtInfo
.
isSuccess
()
||
userExtInfo
.
getData
()
==
null
)
{
return
false
;
}
return
true
;
}
/**
/**
* 清除用户活跃订单
* 清除用户活跃订单
...
@@ -190,12 +170,13 @@ public class XyqbUserServiceImpl implements XyqbUserService {
...
@@ -190,12 +170,13 @@ public class XyqbUserServiceImpl implements XyqbUserService {
return
new
Tuple
<>(
result
,
result
?
"清除用户活跃订单成功"
:
"清除用户活跃订单失败"
);
return
new
Tuple
<>(
result
,
result
?
"清除用户活跃订单成功"
:
"清除用户活跃订单失败"
);
}
}
@Override
public
Boolean
deleteByUserId
(
String
phoneNo
)
{
@OperationAnno
(
channelNo
=
"#this[0]"
,
opt
=
OptEnumName
.
USER_INFO_CLEAN
,
succSPEL
=
"#this.key"
,
optDetailSPEL
=
"#this.value"
)
@Override
public
Tuple
<
Boolean
,
String
>
deleteByUserId
(
String
phoneNo
)
{
try
{
try
{
UserSysResult
<
XUser
>
xUser
=
userSysService
.
getService
().
findUserByPhoneNo
(
phoneNo
);
UserSysResult
<
XUser
>
xUser
=
userSysService
.
getService
().
findUserByPhoneNo
(
phoneNo
);
if
(
xUser
==
null
||
xUser
.
getData
()
==
null
)
{
if
(
xUser
==
null
||
xUser
.
getData
()
==
null
)
{
LOGGER
.
error
(
"cleanUserOrder,删除用户信息失败,未找到用户 phoneNo={}"
,
phoneNo
);
LOGGER
.
error
(
"cleanUserOrder,删除用户信息失败,未找到用户 phoneNo={}"
,
phoneNo
);
return
false
;
return
new
Tuple
<>(
false
,
"删除用户信息失败,未找到用户"
)
;
}
}
Long
userId
=
xUser
.
getData
().
getId
();
Long
userId
=
xUser
.
getData
().
getId
();
int
i
=
userDetailRepository
.
deleteByUserId
(
userId
);
int
i
=
userDetailRepository
.
deleteByUserId
(
userId
);
...
@@ -216,8 +197,8 @@ public class XyqbUserServiceImpl implements XyqbUserService {
...
@@ -216,8 +197,8 @@ public class XyqbUserServiceImpl implements XyqbUserService {
}
}
}
catch
(
Exception
e
){
}
catch
(
Exception
e
){
LOGGER
.
error
(
"cleanUserOrder,删除用户信息失败,phoneNo={}"
,
phoneNo
);
LOGGER
.
error
(
"cleanUserOrder,删除用户信息失败,phoneNo={}"
,
phoneNo
);
return
false
;
return
new
Tuple
<>(
false
,
"删除用户信息失败"
)
;
}
}
return
true
;
return
new
Tuple
<>(
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