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
757cac98
Commit
757cac98
authored
Jan 16, 2024
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
验卷增加判断条件
parent
a046d5ea
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletions
+7
-1
QPServiceImplAspect.java
...ain/java/share/framework/aspectj/QPServiceImplAspect.java
+7
-1
No files found.
share-framework/src/main/java/share/framework/aspectj/QPServiceImplAspect.java
View file @
757cac98
...
...
@@ -155,7 +155,13 @@ public class QPServiceImplAspect {
lambdaQueryWrapper
.
in
(
SConsumerCoupon:
:
getUseStatus
,
UserStatusEnum
.
UNUSED
.
getCode
(),
UserStatusEnum
.
USED
.
getCode
());
List
<
SConsumerCoupon
>
list
=
sConsumerCouponService
.
list
(
lambdaQueryWrapper
);
//过滤只有已使用
SConsumerCoupon
one
=
list
.
stream
().
filter
(
sConsumerCoupon
->
sConsumerCoupon
.
getUseStatus
().
equals
(
UserStatusEnum
.
USED
.
getCode
())).
findFirst
().
orElse
(
null
);
SConsumerCoupon
one
=
null
;
//判断是否存在已使用的券
if
(
list
.
stream
().
anyMatch
(
sConsumerCoupon
->
sConsumerCoupon
.
getUseStatus
().
equals
(
UserStatusEnum
.
USED
.
getCode
())))
{
one
=
list
.
stream
().
filter
(
sConsumerCoupon
->
sConsumerCoupon
.
getUseStatus
().
equals
(
UserStatusEnum
.
USED
.
getCode
())).
findFirst
().
orElse
(
null
);
}
else
{
one
=
list
.
stream
().
filter
(
sConsumerCoupon
->
sConsumerCoupon
.
getUseStatus
().
equals
(
UserStatusEnum
.
UNUSED
.
getCode
())).
findFirst
().
orElse
(
null
);
}
couponLog
.
setConsumerId
(
one
.
getConsumerId
());
couponLog
.
setCouponId
(
one
.
getId
());
LambdaQueryWrapper
<
SStore
>
sStoreLambdaQueryWrapper
=
new
LambdaQueryWrapper
<>();
...
...
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