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
1e0acc0b
Commit
1e0acc0b
authored
Jan 13, 2024
by
wuwenlong
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
139bb74a
14bf0e17
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
16 additions
and
3 deletions
+16
-3
SCouponMapper.java
...stem/src/main/java/share/system/mapper/SCouponMapper.java
+2
-0
ISCouponService.java
...m/src/main/java/share/system/service/ISCouponService.java
+2
-0
QPServiceImpl.java
...rc/main/java/share/system/service/impl/QPServiceImpl.java
+2
-2
SCouponServiceImpl.java
...in/java/share/system/service/impl/SCouponServiceImpl.java
+6
-1
SCouponMapper.xml
...system/src/main/resources/mapper/system/SCouponMapper.xml
+4
-0
No files found.
share-system/src/main/java/share/system/mapper/SCouponMapper.java
View file @
1e0acc0b
...
@@ -64,4 +64,6 @@ public interface SCouponMapper
...
@@ -64,4 +64,6 @@ public interface SCouponMapper
List
<
SCoupon
>
selectSCouponByIds
(
Long
[]
couponIds
);
List
<
SCoupon
>
selectSCouponByIds
(
Long
[]
couponIds
);
List
<
SCoupon
>
listDuration
(
SCoupon
sCoupon
);
List
<
SCoupon
>
listDuration
(
SCoupon
sCoupon
);
List
<
SCoupon
>
selectSCouponByDealgroupId
(
Long
dealgroupId
);
}
}
share-system/src/main/java/share/system/service/ISCouponService.java
View file @
1e0acc0b
...
@@ -71,4 +71,6 @@ public interface ISCouponService
...
@@ -71,4 +71,6 @@ public interface ISCouponService
List
<
SCoupon
>
queryShopDeal
();
List
<
SCoupon
>
queryShopDeal
();
List
<
SCoupon
>
listDuration
(
SCoupon
sCoupon
);
List
<
SCoupon
>
listDuration
(
SCoupon
sCoupon
);
List
<
SCoupon
>
selectSCouponByDealgroupId
(
Long
dealgroupId
);
}
}
share-system/src/main/java/share/system/service/impl/QPServiceImpl.java
View file @
1e0acc0b
...
@@ -144,10 +144,10 @@ public class QPServiceImpl implements QPService {
...
@@ -144,10 +144,10 @@ public class QPServiceImpl implements QPService {
}
}
});
});
List
<
SCoupon
>
sCoupons
=
isCouponService
.
selectSCouponBy
Name
(
prepare
.
getDeal_title
());
List
<
SCoupon
>
sCoupons
=
isCouponService
.
selectSCouponBy
DealgroupId
(
prepare
.
getDealgroup_id
());
SCoupon
sCoupon
=
null
;
SCoupon
sCoupon
=
null
;
if
(!
CollectionUtils
.
isEmpty
(
sCoupons
))
{
if
(!
CollectionUtils
.
isEmpty
(
sCoupons
))
{
sCoupon
=
isCouponService
.
selectSCouponByName
(
prepare
.
getDeal_title
())
.
get
(
0
);
sCoupon
=
sCoupons
.
get
(
0
);
}
}
if
(
ObjectUtils
.
isEmpty
(
sCoupon
))
{
if
(
ObjectUtils
.
isEmpty
(
sCoupon
))
{
sConsumerCoupon
.
setCouponType
(
CouponTypeEnum
.
CASH
.
getCode
());
sConsumerCoupon
.
setCouponType
(
CouponTypeEnum
.
CASH
.
getCode
());
...
...
share-system/src/main/java/share/system/service/impl/SCouponServiceImpl.java
View file @
1e0acc0b
...
@@ -45,7 +45,7 @@ public class SCouponServiceImpl implements ISCouponService {
...
@@ -45,7 +45,7 @@ public class SCouponServiceImpl implements ISCouponService {
//默认优惠开始(有效)时段
//默认优惠开始(有效)时段
private
static
final
String
DEFAULT_START_TIME
=
"00:00"
;
private
static
final
String
DEFAULT_START_TIME
=
"00:00"
;
//默认优惠结束(有效)时段
//默认优惠结束(有效)时段
private
static
final
String
DEFAULT_END_TIME
=
"2
4
:00"
;
private
static
final
String
DEFAULT_END_TIME
=
"2
3
:00"
;
/**
/**
...
@@ -202,4 +202,9 @@ public class SCouponServiceImpl implements ISCouponService {
...
@@ -202,4 +202,9 @@ public class SCouponServiceImpl implements ISCouponService {
public
List
<
SCoupon
>
listDuration
(
SCoupon
sCoupon
)
{
public
List
<
SCoupon
>
listDuration
(
SCoupon
sCoupon
)
{
return
sCouponMapper
.
listDuration
(
sCoupon
);
return
sCouponMapper
.
listDuration
(
sCoupon
);
}
}
@Override
public
List
<
SCoupon
>
selectSCouponByDealgroupId
(
Long
dealgroupId
)
{
return
sCouponMapper
.
selectSCouponByDealgroupId
(
dealgroupId
);
}
}
}
share-system/src/main/resources/mapper/system/SCouponMapper.xml
View file @
1e0acc0b
...
@@ -101,6 +101,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -101,6 +101,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"endDate != null"
>
and end_date >= NOW()
</if>
<if
test=
"endDate != null"
>
and end_date >= NOW()
</if>
</select>
</select>
<select
id=
"selectSCouponByDealgroupId"
resultMap=
"SCouponResult"
>
<include
refid=
"selectSCouponVo"
/>
where dealgroup_id = #{dealgroupId}
</select>
<insert
id=
"insertSCoupon"
parameterType=
"SCoupon"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
<insert
id=
"insertSCoupon"
parameterType=
"SCoupon"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into s_coupon
insert into s_coupon
...
...
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