Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_ht
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
pseer
gxpt_ht
Commits
0f4a390d
Commit
0f4a390d
authored
Sep 14, 2024
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改获取权益会员购买逻辑
parent
680180a4
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
RedisTask.java
share-quartz/src/main/java/share/quartz/task/RedisTask.java
+3
-1
ConsumerWalletServiceImpl.java
.../share/system/service/impl/ConsumerWalletServiceImpl.java
+1
-3
EquityMembersOrderServiceImpl.java
...re/system/service/impl/EquityMembersOrderServiceImpl.java
+1
-1
No files found.
share-quartz/src/main/java/share/quartz/task/RedisTask.java
View file @
0f4a390d
...
@@ -666,8 +666,10 @@ public class RedisTask {
...
@@ -666,8 +666,10 @@ public class RedisTask {
ConsumerMember
consumerMember
=
consumerMemberService
.
getOne
(
new
LambdaQueryWrapper
<
ConsumerMember
>().
eq
(
ConsumerMember:
:
getConsumerId
,
consumerId
));
ConsumerMember
consumerMember
=
consumerMemberService
.
getOne
(
new
LambdaQueryWrapper
<
ConsumerMember
>().
eq
(
ConsumerMember:
:
getConsumerId
,
consumerId
));
consumerMember
.
setIsRights
(
YesNoEnum
.
no
.
getIndex
());
consumerMember
.
setIsRights
(
YesNoEnum
.
no
.
getIndex
());
if
(
ObjectUtil
.
isNotEmpty
(
consumerMember
))
{
if
(
ObjectUtil
.
isNotEmpty
(
consumerMember
))
{
if
(
consumerMember
.
getIsRecharge
().
equals
(
YesNoEnum
.
yes
.
getIndex
()))
{
String
rechargeMembershipExpirationTime
=
sysConfigService
.
selectConfigByKey
(
"rechargeMembershipExpirationTime"
);
String
rechargeMembershipExpirationTime
=
sysConfigService
.
selectConfigByKey
(
"rechargeMembershipExpirationTime"
);
if
(
consumerMember
.
getIsRecharge
().
equals
(
YesNoEnum
.
yes
.
getIndex
()))
{
consumerMember
.
setExpirationDate
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
rechargeMembershipExpirationTime
)));
}
else
{
consumerMember
.
setExpirationDate
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
rechargeMembershipExpirationTime
)));
consumerMember
.
setExpirationDate
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
rechargeMembershipExpirationTime
)));
}
}
// MemberConfig memberConfigServiceOne = memberConfigService.getOne(new LambdaQueryWrapper<MemberConfig>()
// MemberConfig memberConfigServiceOne = memberConfigService.getOne(new LambdaQueryWrapper<MemberConfig>()
...
...
share-system/src/main/java/share/system/service/impl/ConsumerWalletServiceImpl.java
View file @
0f4a390d
...
@@ -211,7 +211,7 @@ public class ConsumerWalletServiceImpl extends ServiceImpl<ConsumerWalletMapper,
...
@@ -211,7 +211,7 @@ public class ConsumerWalletServiceImpl extends ServiceImpl<ConsumerWalletMapper,
String
expirationDateEquityMembership
=
sysConfigService
.
selectConfigByKey
(
"expirationDateEquityMembership"
);
String
expirationDateEquityMembership
=
sysConfigService
.
selectConfigByKey
(
"expirationDateEquityMembership"
);
RechargeConf
rechargeConf
=
rechargeConfService
.
selectRechargeConfById
(
recharge
.
getRechargeConfId
());
RechargeConf
rechargeConf
=
rechargeConfService
.
selectRechargeConfById
(
recharge
.
getRechargeConfId
());
if
(
one
.
getIsRecharge
().
equals
(
YesNoEnum
.
yes
.
getIndex
()))
{
if
(
one
.
getIsRecharge
().
equals
(
YesNoEnum
.
yes
.
getIndex
())
&&
one
.
getIsRights
().
equals
(
YesNoEnum
.
no
.
getIndex
())
)
{
// MemberConfig memberConfig = memberConfigService.getOne(new LambdaQueryWrapper<MemberConfig>()
// MemberConfig memberConfig = memberConfigService.getOne(new LambdaQueryWrapper<MemberConfig>()
// .eq(MemberConfig::getMembershipLevel, one.getMembershipLevel())
// .eq(MemberConfig::getMembershipLevel, one.getMembershipLevel())
// .eq(MemberConfig::getMemberType, MemberTypeEnum.RECHARGE.getIndex())
// .eq(MemberConfig::getMemberType, MemberTypeEnum.RECHARGE.getIndex())
...
@@ -274,9 +274,7 @@ public class ConsumerWalletServiceImpl extends ServiceImpl<ConsumerWalletMapper,
...
@@ -274,9 +274,7 @@ public class ConsumerWalletServiceImpl extends ServiceImpl<ConsumerWalletMapper,
memberProgressLog
.
setOperationTime
(
new
Date
());
memberProgressLog
.
setOperationTime
(
new
Date
());
memberProgressLog
.
setOperationType
(
YesNoEnum
.
yes
.
getIndex
());
memberProgressLog
.
setOperationType
(
YesNoEnum
.
yes
.
getIndex
());
memberProgressLog
.
setCreateTime
(
new
Date
());
memberProgressLog
.
setCreateTime
(
new
Date
());
if
(
one
.
getIsRecharge
().
equals
(
YesNoEnum
.
yes
.
getIndex
()))
{
memberProgressLog
.
setExpirationTime
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
rechargeMembershipExpirationTime
)));
memberProgressLog
.
setExpirationTime
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
rechargeMembershipExpirationTime
)));
}
if
(
one
.
getIsRights
().
equals
(
YesNoEnum
.
yes
.
getIndex
()))
{
if
(
one
.
getIsRights
().
equals
(
YesNoEnum
.
yes
.
getIndex
()))
{
memberProgressLog
.
setExpirationTime
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
expirationDateEquityMembership
)));
memberProgressLog
.
setExpirationTime
(
DateUtils
.
addYears
(
new
Date
(),
Integer
.
parseInt
(
expirationDateEquityMembership
)));
}
}
...
...
share-system/src/main/java/share/system/service/impl/EquityMembersOrderServiceImpl.java
View file @
0f4a390d
...
@@ -148,7 +148,7 @@ public class EquityMembersOrderServiceImpl extends ServiceImpl<EquityMembersOrde
...
@@ -148,7 +148,7 @@ public class EquityMembersOrderServiceImpl extends ServiceImpl<EquityMembersOrde
Date
expirationDate
=
consumerMember
.
getExpirationDate
();
Date
expirationDate
=
consumerMember
.
getExpirationDate
();
//减去当前时间
//减去当前时间
int
i
=
DateUtils
.
differentDaysByMillisecond
(
new
Date
(),
expirationDate
);
int
i
=
DateUtils
.
differentDaysByMillisecond
(
new
Date
(),
expirationDate
);
if
(
i
>
365
)
{
if
(
i
>
365
&&
consumerMember
.
getIsRights
().
equals
(
YesNoEnum
.
yes
.
getIndex
())
)
{
throw
new
BaseException
(
"目前只能购买两年权益会员"
);
throw
new
BaseException
(
"目前只能购买两年权益会员"
);
}
}
}
}
...
...
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