Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-api-boot-master
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
lanbaoming
jiedao-api-boot-master
Commits
6afa9a19
Commit
6afa9a19
authored
Aug 02, 2024
by
zhaobiyan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
唯一键传参
parent
3d427878
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
30 additions
and
30 deletions
+30
-30
MemberUserScoreApiImpl.java
...yudao/module/member/api/score/MemberUserScoreApiImpl.java
+25
-25
MemberUserScoreExpireTask.java
...ember/controller/admin/job/MemberUserScoreExpireTask.java
+1
-1
MemberUserScoreController.java
...controller/admin/userScore/MemberUserScoreController.java
+1
-1
MemberUserScoreDetailExpireListener.java
.../member/listener/MemberUserScoreDetailExpireListener.java
+1
-1
RedeemRewardApiImpl.java
...r/yudao/module/reward/api/reward/RedeemRewardApiImpl.java
+1
-1
RewardRedeemServiceImpl.java
...module/reward/service/redeem/RewardRedeemServiceImpl.java
+1
-1
No files found.
yudao-module-member/yudao-module-member-impl/src/main/java/cn/iocoder/yudao/module/member/api/score/MemberUserScoreApiImpl.java
View file @
6afa9a19
...
@@ -41,7 +41,7 @@ import static cn.iocoder.yudao.module.member.enums.ErrorCodeConstants.*;
...
@@ -41,7 +41,7 @@ import static cn.iocoder.yudao.module.member.enums.ErrorCodeConstants.*;
@Slf4j
@Slf4j
@Service
@Service
public
class
MemberUserScoreApiImpl
implements
MemberUserScoreApi
{
public
class
MemberUserScoreApiImpl
implements
MemberUserScoreApi
{
@Resource
@Resource
private
MemberUserScoreLogService
logService
;
private
MemberUserScoreLogService
logService
;
...
@@ -71,7 +71,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
...
@@ -71,7 +71,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
if
(
StringUtils
.
isBlank
(
req
.
getUniqueId
()))
{
if
(
StringUtils
.
isBlank
(
req
.
getUniqueId
()))
{
throw
exception
(
SCORE_OPERATE_MUST_HAVE_UNIQUE_ID
);
throw
exception
(
SCORE_OPERATE_MUST_HAVE_UNIQUE_ID
);
}
}
MemberUserScoreLogDO
memberUserScoreLogDO
=
logService
.
getByUniqueId
(
req
.
getUniqueId
());
MemberUserScoreLogDO
memberUserScoreLogDO
=
logService
.
getByUniqueId
(
req
.
get
SourceType
()
+
"_"
+
req
.
get
UniqueId
());
if
(
memberUserScoreLogDO
!=
null
)
{
if
(
memberUserScoreLogDO
!=
null
)
{
throw
exception
(
SCORE_OPERATE_IDEMPOTENT_ERROR
);
throw
exception
(
SCORE_OPERATE_IDEMPOTENT_ERROR
);
}
}
...
@@ -86,7 +86,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
...
@@ -86,7 +86,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
List
<
ScoreDetailChangeDto
>
detailInfos
=
saveScoreDetail
(
req
,
logId
);
List
<
ScoreDetailChangeDto
>
detailInfos
=
saveScoreDetail
(
req
,
logId
);
saveScoreDetailReleation
(
req
,
detailInfos
);
saveScoreDetailReleation
(
req
,
detailInfos
);
updateUserScore
(
req
);
updateUserScore
(
req
);
publishDetailExpireEvent
(
req
,
detailInfos
);
publishDetailExpireEvent
(
req
,
detailInfos
);
}
catch
(
InterruptedException
e
)
{
}
catch
(
InterruptedException
e
)
{
throw
exception
(
GET_LOCK_FAILED
);
throw
exception
(
GET_LOCK_FAILED
);
}
finally
{
}
finally
{
...
@@ -96,7 +96,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
...
@@ -96,7 +96,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
}
}
private
void
publishDetailExpireEvent
(
MemberUserScoreOperateReqDTO
req
,
List
<
ScoreDetailChangeDto
>
detailInfos
)
{
private
void
publishDetailExpireEvent
(
MemberUserScoreOperateReqDTO
req
,
List
<
ScoreDetailChangeDto
>
detailInfos
)
{
if
(
req
.
getSourceType
().
getReverseSource
()
==
null
||
req
.
getOperateType
()
==
ScoreOperateTypeEnum
.
REDUCE
)
{
if
(
req
.
getSourceType
().
getReverseSource
()
==
null
||
req
.
getOperateType
()
==
ScoreOperateTypeEnum
.
REDUCE
)
{
return
;
return
;
}
}
//判断回退流程,回退的积分是否过期.如果过期再走正常的过期扣积分流程
//判断回退流程,回退的积分是否过期.如果过期再走正常的过期扣积分流程
...
@@ -199,7 +199,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
...
@@ -199,7 +199,7 @@ public class MemberUserScoreApiImpl implements MemberUserScoreApi{
req
.
getOperateType
().
getValue
()
:
req
.
getSourceType
().
getOperateType
().
getValue
())
req
.
getOperateType
().
getValue
()
:
req
.
getSourceType
().
getOperateType
().
getValue
())
.
sourceType
(
req
.
getSourceType
().
getValue
())
.
sourceType
(
req
.
getSourceType
().
getValue
())
.
extParam
(
req
.
getExtParam
())
.
extParam
(
req
.
getExtParam
())
.
uniqueId
(
req
.
getUniqueId
())
.
uniqueId
(
req
.
get
SourceType
()
+
"_"
+
req
.
get
UniqueId
())
.
build
());
.
build
());
}
}
}
}
yudao-module-member/yudao-module-member-impl/src/main/java/cn/iocoder/yudao/module/member/controller/admin/job/MemberUserScoreExpireTask.java
View file @
6afa9a19
...
@@ -64,7 +64,7 @@ public class MemberUserScoreExpireTask implements JobHandler {
...
@@ -64,7 +64,7 @@ public class MemberUserScoreExpireTask implements JobHandler {
.
memberId
(
memberUserScoreDetailDO
.
getMemberId
())
.
memberId
(
memberUserScoreDetailDO
.
getMemberId
())
.
scoreCount
(
memberUserScoreDetailDO
.
getRemainCount
())
.
scoreCount
(
memberUserScoreDetailDO
.
getRemainCount
())
.
sourceType
(
ScoreSourceTypeEnum
.
SYSTEM_EXPIRED
)
.
sourceType
(
ScoreSourceTypeEnum
.
SYSTEM_EXPIRED
)
.
uniqueId
(
ScoreSourceTypeEnum
.
SYSTEM_EXPIRED
+
"_"
+
memberUserScoreDetailDO
.
getId
()
+
"_"
+
System
.
currentTimeMillis
())
.
uniqueId
(
memberUserScoreDetailDO
.
getId
()
+
"_"
+
System
.
currentTimeMillis
())
.
extParam
(
extParam
)
.
extParam
(
extParam
)
.
build
());
.
build
());
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
...
yudao-module-member/yudao-module-member-impl/src/main/java/cn/iocoder/yudao/module/member/controller/admin/userScore/MemberUserScoreController.java
View file @
6afa9a19
...
@@ -60,7 +60,7 @@ public class MemberUserScoreController {
...
@@ -60,7 +60,7 @@ public class MemberUserScoreController {
.
operateType
(
ScoreOperateTypeEnum
.
parseByValue
(
query
.
getOperateType
()))
.
operateType
(
ScoreOperateTypeEnum
.
parseByValue
(
query
.
getOperateType
()))
.
sourceType
(
ScoreSourceTypeEnum
.
MANUAL_OPERATE
)
.
sourceType
(
ScoreSourceTypeEnum
.
MANUAL_OPERATE
)
.
extParam
(
extParam
)
.
extParam
(
extParam
)
.
uniqueId
(
S
coreSourceTypeEnum
.
MANUAL_OPERATE
+
"_"
+
System
.
currentTimeMillis
(
))
.
uniqueId
(
S
tring
.
valueOf
(
System
.
currentTimeMillis
()
))
.
build
());
.
build
());
return
success
(
null
);
return
success
(
null
);
}
}
...
...
yudao-module-member/yudao-module-member-impl/src/main/java/cn/iocoder/yudao/module/member/listener/MemberUserScoreDetailExpireListener.java
View file @
6afa9a19
...
@@ -55,7 +55,7 @@ public class MemberUserScoreDetailExpireListener {
...
@@ -55,7 +55,7 @@ public class MemberUserScoreDetailExpireListener {
.
memberId
(
detail
.
getMemberId
())
.
memberId
(
detail
.
getMemberId
())
.
scoreCount
(
detail
.
getRemainCount
())
.
scoreCount
(
detail
.
getRemainCount
())
.
sourceType
(
ScoreSourceTypeEnum
.
SYSTEM_EXPIRED
)
.
sourceType
(
ScoreSourceTypeEnum
.
SYSTEM_EXPIRED
)
.
uniqueId
(
ScoreSourceTypeEnum
.
SYSTEM_EXPIRED
+
"_"
+
detail
.
getId
()
+
"_"
+
System
.
currentTimeMillis
())
.
uniqueId
(
detail
.
getId
()
+
"_"
+
System
.
currentTimeMillis
())
.
extParam
(
extParam
)
.
extParam
(
extParam
)
.
build
());
.
build
());
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
...
yudao-module-reward/yudao-module-reward-impl/src/main/java/cn/iocoder/yudao/module/reward/api/reward/RedeemRewardApiImpl.java
View file @
6afa9a19
...
@@ -112,7 +112,7 @@ public class RedeemRewardApiImpl implements RedeemRewardApi {
...
@@ -112,7 +112,7 @@ public class RedeemRewardApiImpl implements RedeemRewardApi {
.
sourceType
(
ScoreSourceTypeEnum
.
EXCHANGE_REWARD
)
.
sourceType
(
ScoreSourceTypeEnum
.
EXCHANGE_REWARD
)
.
scoreCount
(
redeemRewardReqVO
.
getRewardCount
()
*
rewardDO
.
getPointsRequire
())
.
scoreCount
(
redeemRewardReqVO
.
getRewardCount
()
*
rewardDO
.
getPointsRequire
())
.
releationId
(
String
.
valueOf
(
redeemId
))
.
releationId
(
String
.
valueOf
(
redeemId
))
.
uniqueId
(
S
coreSourceTypeEnum
.
EXCHANGE_REWARD
+
"_"
+
redeemId
)
.
uniqueId
(
S
tring
.
valueOf
(
redeemId
)
)
.
extParam
(
extParam
)
.
extParam
(
extParam
)
.
build
());
.
build
());
}
}
...
...
yudao-module-reward/yudao-module-reward-impl/src/main/java/cn/iocoder/yudao/module/reward/service/redeem/RewardRedeemServiceImpl.java
View file @
6afa9a19
...
@@ -274,7 +274,7 @@ public class RewardRedeemServiceImpl extends AbstractService<RewardRedeemMapper,
...
@@ -274,7 +274,7 @@ public class RewardRedeemServiceImpl extends AbstractService<RewardRedeemMapper,
.
scoreCount
(
rewardRedeemDO
.
getScoreCount
())
.
scoreCount
(
rewardRedeemDO
.
getScoreCount
())
.
extParam
(
extParam
)
.
extParam
(
extParam
)
.
releationId
(
String
.
valueOf
(
req
.
getId
()))
.
releationId
(
String
.
valueOf
(
req
.
getId
()))
.
uniqueId
(
S
coreSourceTypeEnum
.
EXCHANGE_REWARD_CANCEL
+
"_"
+
req
.
getId
(
))
.
uniqueId
(
S
tring
.
valueOf
(
req
.
getId
()
))
.
build
());
.
build
());
return
true
;
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