Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
clx-performance
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
姜武杰
clx-performance
Commits
8e25bb5e
提交
8e25bb5e
authored
10月 24, 2023
作者:
jiangwenye
浏览文件
操作
浏览文件
下载
差异文件
Merge remote-tracking branch 'origin/v5.5_settlement_20231011' into v5.5_settlement_20231011
上级
25467211
5b16e3b3
显示空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
64 行增加
和
28 行删除
+64
-28
OwnerAccountServiceImpl.java
...clx/performance/service/impl/OwnerAccountServiceImpl.java
+64
-28
没有找到文件。
performance-web/src/main/java/com/clx/performance/service/impl/OwnerAccountServiceImpl.java
浏览文件 @
8e25bb5e
...
@@ -160,10 +160,7 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -160,10 +160,7 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
update
.
setId
(
account
.
getId
());
update
.
setId
(
account
.
getId
());
Integer
flag
=
ownerAccountDao
.
updateAccountCAS
(
update
,
now
,
false
);
Integer
flag
=
ownerAccountDao
.
updateAccountCAS
(
update
,
now
,
false
);
if
(
null
!=
flag
)
{
if
(
null
!=
flag
)
{
break
;
account
=
ownerAccountDao
.
getAccountByOwnerUserNoAndAccountType
(
param
.
getOwnerUserNo
(),
param
.
getAccountType
());
}
}
//提现记录
//提现记录
OwnerCaseOut
entity
=
new
OwnerCaseOut
();
OwnerCaseOut
entity
=
new
OwnerCaseOut
();
entity
.
setAccountType
(
param
.
getAccountType
());
entity
.
setAccountType
(
param
.
getAccountType
());
...
@@ -175,13 +172,22 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -175,13 +172,22 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
entity
.
setCaseOutBankNumber
(
param
.
getOwnerBankAccount
());
entity
.
setCaseOutBankNumber
(
param
.
getOwnerBankAccount
());
ownerCaseOutDao
.
saveEntity
(
entity
);
ownerCaseOutDao
.
saveEntity
(
entity
);
//插入冻结流水
//插入冻结流水
OwnerRunningWaterRecord
runningWaterRecord
=
new
OwnerRunningWaterRecord
();
OwnerRunningWaterRecord
runningWaterRecord
=
new
OwnerRunningWaterRecord
();
runningWaterRecord
.
setOwnerUserName
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setOwnerUserName
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setMobile
(
loginUserInfo
.
getUserMobile
());
runningWaterRecord
.
setMobile
(
loginUserInfo
.
getUserMobile
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setRelationId
(
entity
.
getCaseOutNo
());
runningWaterRecord
.
setRelationId
(
entity
.
getCaseOutNo
());
runningWaterRecord
.
setAccountBalance
(
caseOutBalance
);
//变动金额
runningWaterRecord
.
setAlterationBalance
(
caseOutBalance
);
//账户余额
runningWaterRecord
.
setAccountBalance
(
account
.
getAccountBalance
());
//冻结金额
runningWaterRecord
.
setFrozenBalance
(
caseOutBalance
);
//扣除金额
runningWaterRecord
.
setTakeOutBalance
(
BigDecimal
.
ZERO
);
runningWaterRecord
.
setOwnerUserNo
(
param
.
getOwnerUserNo
());
runningWaterRecord
.
setOwnerUserNo
(
param
.
getOwnerUserNo
());
runningWaterRecord
.
setAccountType
(
param
.
getAccountType
());
runningWaterRecord
.
setAccountType
(
param
.
getAccountType
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
FROZEN
.
getCode
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
FROZEN
.
getCode
());
...
@@ -190,6 +196,10 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -190,6 +196,10 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
return
entity
.
getCaseOutNo
();
return
entity
.
getCaseOutNo
();
}
}
}
}
@Override
@Override
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
...
@@ -208,10 +218,6 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -208,10 +218,6 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
update
.
setId
(
account
.
getId
());
update
.
setId
(
account
.
getId
());
Integer
flag
=
ownerAccountDao
.
updateAccountCAS
(
update
,
now
,
false
);
Integer
flag
=
ownerAccountDao
.
updateAccountCAS
(
update
,
now
,
false
);
if
(
null
!=
flag
)
{
if
(
null
!=
flag
)
{
break
;
}
}
//提现记录
//提现记录
OwnerCaseOut
entity
=
new
OwnerCaseOut
();
OwnerCaseOut
entity
=
new
OwnerCaseOut
();
entity
.
setAccountType
(
param
.
getAccountType
());
entity
.
setAccountType
(
param
.
getAccountType
());
...
@@ -228,7 +234,17 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -228,7 +234,17 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
runningWaterRecord
.
setMobile
(
loginUserInfo
.
getUserMobile
());
runningWaterRecord
.
setMobile
(
loginUserInfo
.
getUserMobile
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setRelationId
(
entity
.
getCaseOutNo
());
runningWaterRecord
.
setRelationId
(
entity
.
getCaseOutNo
());
runningWaterRecord
.
setAccountBalance
(
caseOutBalance
);
//变动金额
runningWaterRecord
.
setAlterationBalance
(
caseOutBalance
);
//账户余额
runningWaterRecord
.
setAccountBalance
(
account
.
getAccountBalance
());
//冻结金额
runningWaterRecord
.
setFrozenBalance
(
caseOutBalance
);
//扣除金额
runningWaterRecord
.
setTakeOutBalance
(
BigDecimal
.
ZERO
);
runningWaterRecord
.
setOwnerUserNo
(
param
.
getOwnerUserNo
());
runningWaterRecord
.
setOwnerUserNo
(
param
.
getOwnerUserNo
());
runningWaterRecord
.
setAccountType
(
param
.
getAccountType
());
runningWaterRecord
.
setAccountType
(
param
.
getAccountType
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
FROZEN
.
getCode
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
FROZEN
.
getCode
());
...
@@ -237,6 +253,10 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -237,6 +253,10 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
return
entity
.
getCaseOutNo
();
return
entity
.
getCaseOutNo
();
}
}
}
}
/**
/**
* 充值审批
* 充值审批
...
@@ -254,7 +274,6 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -254,7 +274,6 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
entity
.
setApprovalBy
(
loginUserInfo
.
getUserName
());
entity
.
setApprovalBy
(
loginUserInfo
.
getUserName
());
entity
.
setApprovalTime
(
LocalDateTime
.
now
());
entity
.
setApprovalTime
(
LocalDateTime
.
now
());
String
ownerName
=
""
;
if
(!
param
.
getPassType
())
{
if
(!
param
.
getPassType
())
{
entity
.
setId
(
param
.
getId
());
entity
.
setId
(
param
.
getId
());
entity
.
setApprovalTurnDown
(
param
.
getTurnDownContent
());
entity
.
setApprovalTurnDown
(
param
.
getTurnDownContent
());
...
@@ -273,28 +292,33 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -273,28 +292,33 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
update
.
setModifiedTime
(
account
.
getModifiedTime
());
update
.
setModifiedTime
(
account
.
getModifiedTime
());
Integer
flag
=
ownerAccountDao
.
updateAccountCAS
(
update
,
now
,
true
);
Integer
flag
=
ownerAccountDao
.
updateAccountCAS
(
update
,
now
,
true
);
if
(
null
!=
flag
)
{
if
(
null
!=
flag
)
{
ownerName
=
account
.
getOwnerUserName
();
account
=
ownerAccountDao
.
getAccountByOwnerUserNoAndAccountType
(
ownerTopUp
.
getOwnerUserNo
(),
param
.
getAccountType
());
break
;
}
}
entity
.
setId
(
param
.
getId
());
entity
.
setId
(
param
.
getId
());
entity
.
setStatus
(
OwnerAccountEnum
.
TopUpStatus
.
APPROVAL_APPROVE
.
getCode
());
entity
.
setStatus
(
OwnerAccountEnum
.
TopUpStatus
.
APPROVAL_APPROVE
.
getCode
());
ownerTopUpDao
.
updateEntityByKey
(
entity
);
ownerTopUpDao
.
updateEntityByKey
(
entity
);
//需要插入充值流水
//需要插入充值流水
OwnerRunningWaterRecord
runningWaterRecord
=
new
OwnerRunningWaterRecord
();
OwnerRunningWaterRecord
runningWaterRecord
=
new
OwnerRunningWaterRecord
();
runningWaterRecord
.
setOwnerUserName
(
ownerName
);
runningWaterRecord
.
setOwnerUserName
(
account
.
getOwnerUserName
()
);
runningWaterRecord
.
setMobile
(
loginUserInfo
.
getUserMobile
());
runningWaterRecord
.
setMobile
(
loginUserInfo
.
getUserMobile
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setRelationId
(
ownerTopUp
.
getTopUpNo
());
runningWaterRecord
.
setRelationId
(
ownerTopUp
.
getTopUpNo
());
runningWaterRecord
.
setAccountBalance
(
topUpBalance
);
runningWaterRecord
.
setAlterationBalance
(
topUpBalance
);
runningWaterRecord
.
setAccountBalance
(
account
.
getAccountBalance
());
runningWaterRecord
.
setUsableBalance
(
account
.
getUsableBalance
());
runningWaterRecord
.
setFrozenBalance
(
account
.
getFrozenBalance
());
runningWaterRecord
.
setOwnerUserNo
(
ownerTopUp
.
getOwnerUserNo
());
runningWaterRecord
.
setOwnerUserNo
(
ownerTopUp
.
getOwnerUserNo
());
runningWaterRecord
.
setAccountType
(
param
.
getAccountType
());
runningWaterRecord
.
setAccountType
(
param
.
getAccountType
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
TOP_UP
.
getCode
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
TOP_UP
.
getCode
());
runningWaterRecord
.
setRunningWaterNo
(
idGenerateSnowFlake
.
nextId
(
IdTypeEnum
.
Type
.
TOP_UP_SUCCESS
.
getCode
()));
runningWaterRecord
.
setRunningWaterNo
(
idGenerateSnowFlake
.
nextId
(
IdTypeEnum
.
Type
.
TOP_UP_SUCCESS
.
getCode
()));
ownerRunningWaterRecordDao
.
saveEntity
(
runningWaterRecord
);
ownerRunningWaterRecordDao
.
saveEntity
(
runningWaterRecord
);
break
;
}
}
}
}
}
}
...
@@ -340,16 +364,7 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -340,16 +364,7 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
update
.
setModifiedTime
(
account
.
getModifiedTime
());
update
.
setModifiedTime
(
account
.
getModifiedTime
());
Integer
flag
=
ownerAccountDao
.
updateOwnerAccountForConfirm
(
update
);
Integer
flag
=
ownerAccountDao
.
updateOwnerAccountForConfirm
(
update
);
if
(
flag
>
0
)
{
if
(
flag
>
0
)
{
break
;
account
=
ownerAccountDao
.
getAccountByOwnerUserNoAndAccountType
(
ownerCaseOut
.
getOwnerUserNo
(),
ownerCaseOut
.
getAccountType
());
}
}
//更新提现状态
OwnerCaseOut
entity
=
new
OwnerCaseOut
();
entity
.
setId
(
ownerCaseOut
.
getId
());
entity
.
setStatus
(
OwnerAccountEnum
.
CaseOutStatus
.
PAID
.
getCode
());
ownerCaseOutDao
.
updateEntityByKey
(
entity
);
//插入提现成功流水
//插入提现成功流水
OwnerRunningWaterRecord
runningWaterRecord
=
new
OwnerRunningWaterRecord
();
OwnerRunningWaterRecord
runningWaterRecord
=
new
OwnerRunningWaterRecord
();
runningWaterRecord
.
setOwnerUserName
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setOwnerUserName
(
loginUserInfo
.
getUserName
());
...
@@ -357,13 +372,34 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
...
@@ -357,13 +372,34 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setCreateBy
(
loginUserInfo
.
getUserName
());
runningWaterRecord
.
setRelationId
(
ownerCaseOut
.
getCaseOutNo
());
runningWaterRecord
.
setRelationId
(
ownerCaseOut
.
getCaseOutNo
());
runningWaterRecord
.
setAccountBalance
(
caseOutBalance
);
//账户余额
runningWaterRecord
.
setAccountBalance
(
account
.
getAccountBalance
());
//变动余额
runningWaterRecord
.
setAlterationBalance
(
caseOutBalance
);
//可用余额
runningWaterRecord
.
setUsableBalance
(
account
.
getUsableBalance
());
//扣除金额
runningWaterRecord
.
setTakeOutBalance
(
caseOutBalance
);
//冻结金额
runningWaterRecord
.
setFrozenBalance
(
BigDecimal
.
ZERO
);
runningWaterRecord
.
setOwnerUserNo
(
ownerCaseOut
.
getOwnerUserNo
());
runningWaterRecord
.
setOwnerUserNo
(
ownerCaseOut
.
getOwnerUserNo
());
runningWaterRecord
.
setAccountType
(
ownerCaseOut
.
getAccountType
());
runningWaterRecord
.
setAccountType
(
ownerCaseOut
.
getAccountType
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
CASE_OUT_SUCCESS
.
getCode
());
runningWaterRecord
.
setRunningWaterType
(
OwnerAccountEnum
.
RunningWaterStatus
.
CASE_OUT_SUCCESS
.
getCode
());
runningWaterRecord
.
setRunningWaterNo
(
idGenerateSnowFlake
.
nextId
(
IdTypeEnum
.
Type
.
CASE_OUT_SUCCESS
.
getCode
()));
runningWaterRecord
.
setRunningWaterNo
(
idGenerateSnowFlake
.
nextId
(
IdTypeEnum
.
Type
.
CASE_OUT_SUCCESS
.
getCode
()));
ownerRunningWaterRecordDao
.
saveEntity
(
runningWaterRecord
);
ownerRunningWaterRecordDao
.
saveEntity
(
runningWaterRecord
);
break
;
}
}
//更新提现状态
OwnerCaseOut
entity
=
new
OwnerCaseOut
();
entity
.
setId
(
ownerCaseOut
.
getId
());
entity
.
setStatus
(
OwnerAccountEnum
.
CaseOutStatus
.
PAID
.
getCode
());
ownerCaseOutDao
.
updateEntityByKey
(
entity
);
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论