Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gogirl-miniapp-backend
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
huluobin
gogirl-miniapp-backend
Commits
1b65b5ac
Commit
1b65b5ac
authored
Mar 25, 2020
by
huluobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
order pay
parent
4c480d01
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
5 deletions
+26
-5
CouponServiceImpl.java
...com/gogirl/application/market/impl/CouponServiceImpl.java
+3
-1
Coupon.java
src/main/java/com/gogirl/domain/market/coupon/Coupon.java
+23
-4
No files found.
src/main/java/com/gogirl/application/market/impl/CouponServiceImpl.java
View file @
1b65b5ac
...
...
@@ -213,7 +213,9 @@ public class CouponServiceImpl extends ServiceImpl<CouponMapper, Coupon> impleme
OrderManage
orderManage
=
orderManageMapper
.
selectById
(
orderId
);
List
<
OrderServe
>
orderServeList
=
orderServeMapper
.
selectList
(
new
LambdaQueryWrapper
<
OrderServe
>().
eq
(
OrderServe:
:
getOrderId
,
orderId
));
return
couponMapper
.
selectList
(
new
LambdaQueryWrapper
<
Coupon
>().
eq
(
Coupon:
:
getSourceType
,
1
))
.
selectList
(
new
LambdaQueryWrapper
<
Coupon
>()
.
eq
(
Coupon:
:
getSourceType
,
1
)
.
eq
(
Coupon:
:
getState
,
1
))
.
stream
()
//过滤所有可用在服务上的
.
filter
(
coupon
->
{
...
...
src/main/java/com/gogirl/domain/market/coupon/Coupon.java
View file @
1b65b5ac
...
...
@@ -8,7 +8,6 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
org.springframework.format.annotation.DateTimeFormat
;
import
java.math.BigDecimal
;
import
java.util.Date
;
...
...
@@ -21,56 +20,76 @@ public class Coupon {
@TableId
(
type
=
IdType
.
AUTO
)
private
Integer
id
;
@ApiModelProperty
(
"券名称"
)
private
String
name
;
@ApiModelProperty
(
"优惠金额"
)
private
BigDecimal
discountAmount
;
@ApiModelProperty
(
"满这个金额才能减"
)
private
BigDecimal
reachingAmount
;
@ApiModelProperty
(
"优惠折扣"
)
private
BigDecimal
discountPercent
;
@ApiModelProperty
(
"优惠券类型:1.现金抵扣券;2.免单券;3满减券;4卸甲券;5 = 折扣券"
)
private
Integer
type
;
@ApiModelProperty
(
"使用条件:1.重叠使用"
)
private
String
condition1
;
@ApiModelProperty
(
"优惠券说明"
)
private
String
note
;
@ApiModelProperty
(
"有效期类型:1.开始和结束时间;2.有效天数"
)
private
Integer
validType
;
@ApiModelProperty
(
"有效天数"
)
private
Integer
validDate
;
@ApiModelProperty
(
"0 = 内部券 1 = 外部券"
)
private
Integer
sourceType
;
@DateTimeFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@ApiModelProperty
(
"有效期,开始时间"
)
private
Date
validStartTime
;
@DateTimeFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@ApiModelProperty
(
"有效期,截止时间"
)
private
Date
validEndTime
;
@ApiModelProperty
(
"总数量"
)
private
Integer
allQuantity
;
@ApiModelProperty
(
"发放数量"
)
private
Integer
receiveQuantity
;
@ApiModelProperty
(
"使用次数"
)
private
Integer
useQuantity
;
@ApiModelProperty
(
"每人最多领取次数"
)
private
Integer
limitQuantity
;
@ApiModelProperty
(
"状态:1.启用;2.停止"
)
private
Integer
state
;
@ApiModelProperty
(
"最近更新时间,用于排序"
)
private
Date
updateTime
;
@ApiModelProperty
(
"备注"
)
private
String
remark
;
@ApiModelProperty
(
"客户购买该券时,实际支付的金额(用该金额算业绩)"
)
private
BigDecimal
payAmount
;
@ApiModelProperty
(
"7:大众点评收款,10:免单(外部券购买时钱去到哪里了和customer_balance_record表的source字段保持一致)"
)
private
String
paySource
;
@ApiModelProperty
(
"1-计算 2-不计算"
)
@ApiModelProperty
(
"
是否计算业绩
1-计算 2-不计算"
)
private
Integer
isCalcAchievement
;
@TableField
(
exist
=
false
)
@ApiModelProperty
(
"是否可以使用"
)
private
Boolean
canBeUse
;
}
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