Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
usedCarAuction
/
aus
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 5d165304
authored
May 19, 2026
by
章家宝
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
feat:优惠券使用门槛做校验 0 - 999 9999.99
1 parent
71b2e316
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
7 deletions
aus-core/src/main/java/com/glsx/usedcar/module/coupon/dao/CouponActivityRepository.java
aus-core/src/main/java/com/glsx/usedcar/module/coupon/service/CouponActivityService.java
aus-core/src/main/java/com/glsx/usedcar/module/coupon/vo/CouponTemplateAddVO.java
aus-core/src/main/java/com/glsx/usedcar/module/coupon/vo/CouponTemplateUpdateVO.java
aus-core/src/main/java/com/glsx/usedcar/module/coupon/dao/CouponActivityRepository.java
View file @
5d16530
...
@@ -181,8 +181,8 @@ public interface CouponActivityRepository extends BaseRepository<CouponActivity,
...
@@ -181,8 +181,8 @@ public interface CouponActivityRepository extends BaseRepository<CouponActivity,
AND (:searchKey IS NULL OR ca.activity_name LIKE CONCAT('%', :searchKey, '%') OR ca.activity_id LIKE CONCAT('%', :searchKey, '%'))
AND (:searchKey IS NULL OR ca.activity_name LIKE CONCAT('%', :searchKey, '%') OR ca.activity_id LIKE CONCAT('%', :searchKey, '%'))
AND (:status IS NULL OR ca.status = :status)
AND (:status IS NULL OR ca.status = :status)
AND (:activityType IS NULL OR ca.activity_type = :activityType)
AND (:activityType IS NULL OR ca.activity_type = :activityType)
AND (:startTime IS NULL OR ca.
create
_time >= :startTime)
AND (:startTime IS NULL OR ca.
valid_end
_time >= :startTime)
AND (:endTime IS NULL OR ca.
create
_time <= :endTime)
AND (:endTime IS NULL OR ca.
valid_start
_time <= :endTime)
GROUP BY ca.id, ca.activity_id, ca.activity_name, ca.valid_start_time, ca.valid_end_time,
GROUP BY ca.id, ca.activity_id, ca.activity_name, ca.valid_start_time, ca.valid_end_time,
ca.activity_type, ca.target_type, ca.distribution_quantity, ca.status,
ca.activity_type, ca.target_type, ca.distribution_quantity, ca.status,
ca.create_time, ca.send_notification, ca.remark, ca.update_time, ca.template_id
ca.create_time, ca.send_notification, ca.remark, ca.update_time, ca.template_id
...
@@ -209,8 +209,8 @@ public interface CouponActivityRepository extends BaseRepository<CouponActivity,
...
@@ -209,8 +209,8 @@ public interface CouponActivityRepository extends BaseRepository<CouponActivity,
AND (:searchKey IS NULL OR ca.activity_name LIKE CONCAT('%', :searchKey, '%') OR ca.activity_id LIKE CONCAT('%', :searchKey, '%'))
AND (:searchKey IS NULL OR ca.activity_name LIKE CONCAT('%', :searchKey, '%') OR ca.activity_id LIKE CONCAT('%', :searchKey, '%'))
AND (:status IS NULL OR ca.status = :status)
AND (:status IS NULL OR ca.status = :status)
AND (:activityType IS NULL OR ca.activity_type = :activityType)
AND (:activityType IS NULL OR ca.activity_type = :activityType)
AND (:startTime IS NULL OR ca.
create
_time >= :startTime)
AND (:startTime IS NULL OR ca.
valid_end
_time >= :startTime)
AND (:endTime IS NULL OR ca.
create
_time <= :endTime)
AND (:endTime IS NULL OR ca.
valid_start
_time <= :endTime)
"""
,
"""
,
nativeQuery
=
true
)
nativeQuery
=
true
)
Page
<
CouponActivityStatDTO
>
pageActivityStat
(
Page
<
CouponActivityStatDTO
>
pageActivityStat
(
...
...
aus-core/src/main/java/com/glsx/usedcar/module/coupon/service/CouponActivityService.java
View file @
5d16530
...
@@ -476,7 +476,7 @@ public class CouponActivityService {
...
@@ -476,7 +476,7 @@ public class CouponActivityService {
Integer
activityType
=
typeObj
instanceof
Integer
?
(
Integer
)
typeObj
:
null
;
Integer
activityType
=
typeObj
instanceof
Integer
?
(
Integer
)
typeObj
:
null
;
@SuppressWarnings
(
"unchecked"
)
@SuppressWarnings
(
"unchecked"
)
List
<
String
>
timeRange
=
(
List
<
String
>)
pagination
.
getFilterValueOrElseNull
(
"
create
Time"
);
List
<
String
>
timeRange
=
(
List
<
String
>)
pagination
.
getFilterValueOrElseNull
(
"
valid
Time"
);
LocalDateTime
[]
parsedRange
=
parseTimeRange
(
timeRange
);
LocalDateTime
[]
parsedRange
=
parseTimeRange
(
timeRange
);
LocalDateTime
startTime
=
parsedRange
[
0
];
LocalDateTime
startTime
=
parsedRange
[
0
];
LocalDateTime
endTime
=
parsedRange
[
1
];
LocalDateTime
endTime
=
parsedRange
[
1
];
...
...
aus-core/src/main/java/com/glsx/usedcar/module/coupon/vo/CouponTemplateAddVO.java
View file @
5d16530
...
@@ -35,7 +35,7 @@ public class CouponTemplateAddVO implements Serializable {
...
@@ -35,7 +35,7 @@ public class CouponTemplateAddVO implements Serializable {
@Schema
(
description
=
"使用门槛(元,0 代表无门槛)"
,
requiredMode
=
Schema
.
RequiredMode
.
NOT_REQUIRED
,
example
=
"10000.00"
)
@Schema
(
description
=
"使用门槛(元,0 代表无门槛)"
,
requiredMode
=
Schema
.
RequiredMode
.
NOT_REQUIRED
,
example
=
"10000.00"
)
@DecimalMin
(
value
=
"0"
,
message
=
"门槛必须>=0"
)
@DecimalMin
(
value
=
"0"
,
message
=
"门槛必须>=0"
)
@DecimalMax
(
value
=
"
9999999"
,
message
=
"门槛必须<=9999999
"
)
@DecimalMax
(
value
=
"
10000000"
,
message
=
"门槛必须<=10000000
"
)
private
BigDecimal
thresholdAmount
;
private
BigDecimal
thresholdAmount
;
@Schema
(
description
=
"抵扣类型 (1:抵扣车款;2:抵扣佣金)"
,
requiredMode
=
Schema
.
RequiredMode
.
REQUIRED
,
example
=
"2"
)
@Schema
(
description
=
"抵扣类型 (1:抵扣车款;2:抵扣佣金)"
,
requiredMode
=
Schema
.
RequiredMode
.
REQUIRED
,
example
=
"2"
)
...
...
aus-core/src/main/java/com/glsx/usedcar/module/coupon/vo/CouponTemplateUpdateVO.java
View file @
5d16530
...
@@ -39,7 +39,7 @@ public class CouponTemplateUpdateVO implements Serializable {
...
@@ -39,7 +39,7 @@ public class CouponTemplateUpdateVO implements Serializable {
@Schema
(
description
=
"使用门槛(元,0 代表无门槛)"
,
requiredMode
=
Schema
.
RequiredMode
.
NOT_REQUIRED
,
example
=
"10000.00"
)
@Schema
(
description
=
"使用门槛(元,0 代表无门槛)"
,
requiredMode
=
Schema
.
RequiredMode
.
NOT_REQUIRED
,
example
=
"10000.00"
)
@DecimalMin
(
value
=
"0"
,
message
=
"门槛必须>=0"
)
@DecimalMin
(
value
=
"0"
,
message
=
"门槛必须>=0"
)
@DecimalMax
(
value
=
"
9999999"
,
message
=
"门槛必须<=9999999
"
)
@DecimalMax
(
value
=
"
10000000"
,
message
=
"门槛必须<=10000000
"
)
private
BigDecimal
thresholdAmount
;
private
BigDecimal
thresholdAmount
;
@Schema
(
description
=
"抵扣类型 (1:抵扣车款;2:抵扣佣金)"
,
requiredMode
=
Schema
.
RequiredMode
.
REQUIRED
,
example
=
"2"
)
@Schema
(
description
=
"抵扣类型 (1:抵扣车款;2:抵扣佣金)"
,
requiredMode
=
Schema
.
RequiredMode
.
REQUIRED
,
example
=
"2"
)
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment