Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Litemall
Commits
0d017bde
Commit
0d017bde
authored
Dec 16, 2019
by
Junling Bu
Browse files
feat[litemall-db]: 订单表记录部分退款信息
parent
1d1c017b
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
litemall-db/sql/litemall_table.sql
View file @
0d017bde
...
...
@@ -540,6 +540,10 @@ CREATE TABLE `litemall_order` (
`ship_sn`
varchar
(
63
)
DEFAULT
NULL
COMMENT
'发货编号'
,
`ship_channel`
varchar
(
63
)
DEFAULT
NULL
COMMENT
'发货快递公司'
,
`ship_time`
datetime
DEFAULT
NULL
COMMENT
'发货开始时间'
,
`refund_amount`
decimal
(
10
,
2
)
DEFAULT
NULL
COMMENT
'实际退款金额,(有可能退款金额小于实际支付金额)'
,
`refund_type`
varchar
(
63
)
DEFAULT
NULL
COMMENT
'退款方式'
,
`refund_content`
varchar
(
127
)
DEFAULT
NULL
COMMENT
'退款备注'
,
`refund_time`
datetime
DEFAULT
NULL
COMMENT
'退款时间'
,
`confirm_time`
datetime
DEFAULT
NULL
COMMENT
'用户确认收货时间'
,
`comments`
smallint
(
6
)
DEFAULT
'0'
COMMENT
'待评价订单商品数量'
,
`end_time`
datetime
DEFAULT
NULL
COMMENT
'订单关闭时间'
,
...
...
@@ -691,7 +695,7 @@ CREATE TABLE `litemall_system` (
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
tinyint
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除'
,
PRIMARY
KEY
(
`id`
)
USING
BTREE
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
ROW_FORMAT
=
DYNAMIC
COMMENT
=
'系统配置表'
;
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
19
DEFAULT
CHARSET
=
utf8mb4
ROW_FORMAT
=
DYNAMIC
COMMENT
=
'系统配置表'
;
/*!40101 SET character_set_client = @saved_cs_client */
;
--
...
...
@@ -779,4 +783,4 @@ CREATE TABLE `litemall_user_formid` (
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */
;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */
;
-- Dump completed on 201
8
-12-1
0 16:59:09
-- Dump completed on 201
9
-12-1
6 23:12:57
litemall-db/src/main/java/org/linlinjava/litemall/db/domain/LitemallOrder.java
View file @
0d017bde
...
...
@@ -202,6 +202,42 @@ public class LitemallOrder {
*/
private
LocalDateTime
shipTime
;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column litemall_order.refund_amount
*
* @mbg.generated
*/
private
BigDecimal
refundAmount
;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column litemall_order.refund_type
*
* @mbg.generated
*/
private
String
refundType
;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column litemall_order.refund_content
*
* @mbg.generated
*/
private
String
refundContent
;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column litemall_order.refund_time
*
* @mbg.generated
*/
private
LocalDateTime
refundTime
;
/**
*
* This field was generated by MyBatis Generator.
...
...
@@ -736,6 +772,102 @@ public class LitemallOrder {
this
.
shipTime
=
shipTime
;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column litemall_order.refund_amount
*
* @return the value of litemall_order.refund_amount
*
* @mbg.generated
*/
public
BigDecimal
getRefundAmount
()
{
return
refundAmount
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column litemall_order.refund_amount
*
* @param refundAmount the value for litemall_order.refund_amount
*
* @mbg.generated
*/
public
void
setRefundAmount
(
BigDecimal
refundAmount
)
{
this
.
refundAmount
=
refundAmount
;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column litemall_order.refund_type
*
* @return the value of litemall_order.refund_type
*
* @mbg.generated
*/
public
String
getRefundType
()
{
return
refundType
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column litemall_order.refund_type
*
* @param refundType the value for litemall_order.refund_type
*
* @mbg.generated
*/
public
void
setRefundType
(
String
refundType
)
{
this
.
refundType
=
refundType
;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column litemall_order.refund_content
*
* @return the value of litemall_order.refund_content
*
* @mbg.generated
*/
public
String
getRefundContent
()
{
return
refundContent
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column litemall_order.refund_content
*
* @param refundContent the value for litemall_order.refund_content
*
* @mbg.generated
*/
public
void
setRefundContent
(
String
refundContent
)
{
this
.
refundContent
=
refundContent
;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column litemall_order.refund_time
*
* @return the value of litemall_order.refund_time
*
* @mbg.generated
*/
public
LocalDateTime
getRefundTime
()
{
return
refundTime
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column litemall_order.refund_time
*
* @param refundTime the value for litemall_order.refund_time
*
* @mbg.generated
*/
public
void
setRefundTime
(
LocalDateTime
refundTime
)
{
this
.
refundTime
=
refundTime
;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column litemall_order.confirm_time
...
...
@@ -924,6 +1056,10 @@ public class LitemallOrder {
sb
.
append
(
", shipSn="
).
append
(
shipSn
);
sb
.
append
(
", shipChannel="
).
append
(
shipChannel
);
sb
.
append
(
", shipTime="
).
append
(
shipTime
);
sb
.
append
(
", refundAmount="
).
append
(
refundAmount
);
sb
.
append
(
", refundType="
).
append
(
refundType
);
sb
.
append
(
", refundContent="
).
append
(
refundContent
);
sb
.
append
(
", refundTime="
).
append
(
refundTime
);
sb
.
append
(
", confirmTime="
).
append
(
confirmTime
);
sb
.
append
(
", comments="
).
append
(
comments
);
sb
.
append
(
", endTime="
).
append
(
endTime
);
...
...
@@ -972,6 +1108,10 @@ public class LitemallOrder {
&&
(
this
.
getShipSn
()
==
null
?
other
.
getShipSn
()
==
null
:
this
.
getShipSn
().
equals
(
other
.
getShipSn
()))
&&
(
this
.
getShipChannel
()
==
null
?
other
.
getShipChannel
()
==
null
:
this
.
getShipChannel
().
equals
(
other
.
getShipChannel
()))
&&
(
this
.
getShipTime
()
==
null
?
other
.
getShipTime
()
==
null
:
this
.
getShipTime
().
equals
(
other
.
getShipTime
()))
&&
(
this
.
getRefundAmount
()
==
null
?
other
.
getRefundAmount
()
==
null
:
this
.
getRefundAmount
().
equals
(
other
.
getRefundAmount
()))
&&
(
this
.
getRefundType
()
==
null
?
other
.
getRefundType
()
==
null
:
this
.
getRefundType
().
equals
(
other
.
getRefundType
()))
&&
(
this
.
getRefundContent
()
==
null
?
other
.
getRefundContent
()
==
null
:
this
.
getRefundContent
().
equals
(
other
.
getRefundContent
()))
&&
(
this
.
getRefundTime
()
==
null
?
other
.
getRefundTime
()
==
null
:
this
.
getRefundTime
().
equals
(
other
.
getRefundTime
()))
&&
(
this
.
getConfirmTime
()
==
null
?
other
.
getConfirmTime
()
==
null
:
this
.
getConfirmTime
().
equals
(
other
.
getConfirmTime
()))
&&
(
this
.
getComments
()
==
null
?
other
.
getComments
()
==
null
:
this
.
getComments
().
equals
(
other
.
getComments
()))
&&
(
this
.
getEndTime
()
==
null
?
other
.
getEndTime
()
==
null
:
this
.
getEndTime
().
equals
(
other
.
getEndTime
()))
...
...
@@ -1010,6 +1150,10 @@ public class LitemallOrder {
result
=
prime
*
result
+
((
getShipSn
()
==
null
)
?
0
:
getShipSn
().
hashCode
());
result
=
prime
*
result
+
((
getShipChannel
()
==
null
)
?
0
:
getShipChannel
().
hashCode
());
result
=
prime
*
result
+
((
getShipTime
()
==
null
)
?
0
:
getShipTime
().
hashCode
());
result
=
prime
*
result
+
((
getRefundAmount
()
==
null
)
?
0
:
getRefundAmount
().
hashCode
());
result
=
prime
*
result
+
((
getRefundType
()
==
null
)
?
0
:
getRefundType
().
hashCode
());
result
=
prime
*
result
+
((
getRefundContent
()
==
null
)
?
0
:
getRefundContent
().
hashCode
());
result
=
prime
*
result
+
((
getRefundTime
()
==
null
)
?
0
:
getRefundTime
().
hashCode
());
result
=
prime
*
result
+
((
getConfirmTime
()
==
null
)
?
0
:
getConfirmTime
().
hashCode
());
result
=
prime
*
result
+
((
getComments
()
==
null
)
?
0
:
getComments
().
hashCode
());
result
=
prime
*
result
+
((
getEndTime
()
==
null
)
?
0
:
getEndTime
().
hashCode
());
...
...
@@ -1114,6 +1258,10 @@ public class LitemallOrder {
shipSn
(
"ship_sn"
,
"shipSn"
,
"VARCHAR"
,
false
),
shipChannel
(
"ship_channel"
,
"shipChannel"
,
"VARCHAR"
,
false
),
shipTime
(
"ship_time"
,
"shipTime"
,
"TIMESTAMP"
,
false
),
refundAmount
(
"refund_amount"
,
"refundAmount"
,
"DECIMAL"
,
false
),
refundType
(
"refund_type"
,
"refundType"
,
"VARCHAR"
,
false
),
refundContent
(
"refund_content"
,
"refundContent"
,
"VARCHAR"
,
false
),
refundTime
(
"refund_time"
,
"refundTime"
,
"TIMESTAMP"
,
false
),
confirmTime
(
"confirm_time"
,
"confirmTime"
,
"TIMESTAMP"
,
false
),
comments
(
"comments"
,
"comments"
,
"SMALLINT"
,
false
),
endTime
(
"end_time"
,
"endTime"
,
"TIMESTAMP"
,
false
),
...
...
litemall-db/src/main/java/org/linlinjava/litemall/db/domain/LitemallOrderExample.java
View file @
0d017bde
This diff is collapsed.
Click to expand it.
litemall-db/src/main/resources/org/linlinjava/litemall/db/dao/LitemallOrderMapper.xml
View file @
0d017bde
...
...
@@ -26,6 +26,10 @@
<result
column=
"ship_sn"
jdbcType=
"VARCHAR"
property=
"shipSn"
/>
<result
column=
"ship_channel"
jdbcType=
"VARCHAR"
property=
"shipChannel"
/>
<result
column=
"ship_time"
jdbcType=
"TIMESTAMP"
property=
"shipTime"
/>
<result
column=
"refund_amount"
jdbcType=
"DECIMAL"
property=
"refundAmount"
/>
<result
column=
"refund_type"
jdbcType=
"VARCHAR"
property=
"refundType"
/>
<result
column=
"refund_content"
jdbcType=
"VARCHAR"
property=
"refundContent"
/>
<result
column=
"refund_time"
jdbcType=
"TIMESTAMP"
property=
"refundTime"
/>
<result
column=
"confirm_time"
jdbcType=
"TIMESTAMP"
property=
"confirmTime"
/>
<result
column=
"comments"
jdbcType=
"SMALLINT"
property=
"comments"
/>
<result
column=
"end_time"
jdbcType=
"TIMESTAMP"
property=
"endTime"
/>
...
...
@@ -106,8 +110,8 @@
-->
id, user_id, order_sn, order_status, consignee, mobile, address, message, goods_price,
freight_price, coupon_price, integral_price, groupon_price, order_price, actual_price,
pay_id, pay_time, ship_sn, ship_channel, ship_time,
confirm_time, comments, end_time
,
add_time, update_time, deleted
pay_id, pay_time, ship_sn, ship_channel, ship_time,
refund_amount, refund_type, refund_content
,
refund_time, confirm_time, comments, end_time,
add_time, update_time, deleted
</sql>
<select
id=
"selectByExample"
parameterType=
"org.linlinjava.litemall.db.domain.LitemallOrderExample"
resultMap=
"BaseResultMap"
>
<!--
...
...
@@ -234,18 +238,20 @@
coupon_price, integral_price, groupon_price,
order_price, actual_price, pay_id,
pay_time, ship_sn, ship_channel,
ship_time, confirm_time, comments,
end_time, add_time, update_time,
deleted)
ship_time, refund_amount, refund_type,
refund_content, refund_time, confirm_time,
comments, end_time, add_time,
update_time, deleted)
values (#{userId,jdbcType=INTEGER}, #{orderSn,jdbcType=VARCHAR}, #{orderStatus,jdbcType=SMALLINT},
#{consignee,jdbcType=VARCHAR}, #{mobile,jdbcType=VARCHAR}, #{address,jdbcType=VARCHAR},
#{message,jdbcType=VARCHAR}, #{goodsPrice,jdbcType=DECIMAL}, #{freightPrice,jdbcType=DECIMAL},
#{couponPrice,jdbcType=DECIMAL}, #{integralPrice,jdbcType=DECIMAL}, #{grouponPrice,jdbcType=DECIMAL},
#{orderPrice,jdbcType=DECIMAL}, #{actualPrice,jdbcType=DECIMAL}, #{payId,jdbcType=VARCHAR},
#{payTime,jdbcType=TIMESTAMP}, #{shipSn,jdbcType=VARCHAR}, #{shipChannel,jdbcType=VARCHAR},
#{shipTime,jdbcType=TIMESTAMP}, #{confirmTime,jdbcType=TIMESTAMP}, #{comments,jdbcType=SMALLINT},
#{endTime,jdbcType=TIMESTAMP}, #{addTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP},
#{deleted,jdbcType=BIT})
#{shipTime,jdbcType=TIMESTAMP}, #{refundAmount,jdbcType=DECIMAL}, #{refundType,jdbcType=VARCHAR},
#{refundContent,jdbcType=VARCHAR}, #{refundTime,jdbcType=TIMESTAMP}, #{confirmTime,jdbcType=TIMESTAMP},
#{comments,jdbcType=SMALLINT}, #{endTime,jdbcType=TIMESTAMP}, #{addTime,jdbcType=TIMESTAMP},
#{updateTime,jdbcType=TIMESTAMP}, #{deleted,jdbcType=BIT})
</insert>
<insert
id=
"insertSelective"
parameterType=
"org.linlinjava.litemall.db.domain.LitemallOrder"
>
<!--
...
...
@@ -314,6 +320,18 @@
<if
test=
"shipTime != null"
>
ship_time,
</if>
<if
test=
"refundAmount != null"
>
refund_amount,
</if>
<if
test=
"refundType != null"
>
refund_type,
</if>
<if
test=
"refundContent != null"
>
refund_content,
</if>
<if
test=
"refundTime != null"
>
refund_time,
</if>
<if
test=
"confirmTime != null"
>
confirm_time,
</if>
...
...
@@ -391,6 +409,18 @@
<if
test=
"shipTime != null"
>
#{shipTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"refundAmount != null"
>
#{refundAmount,jdbcType=DECIMAL},
</if>
<if
test=
"refundType != null"
>
#{refundType,jdbcType=VARCHAR},
</if>
<if
test=
"refundContent != null"
>
#{refundContent,jdbcType=VARCHAR},
</if>
<if
test=
"refundTime != null"
>
#{refundTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"confirmTime != null"
>
#{confirmTime,jdbcType=TIMESTAMP},
</if>
...
...
@@ -488,6 +518,18 @@
<if
test=
"record.shipTime != null"
>
ship_time = #{record.shipTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"record.refundAmount != null"
>
refund_amount = #{record.refundAmount,jdbcType=DECIMAL},
</if>
<if
test=
"record.refundType != null"
>
refund_type = #{record.refundType,jdbcType=VARCHAR},
</if>
<if
test=
"record.refundContent != null"
>
refund_content = #{record.refundContent,jdbcType=VARCHAR},
</if>
<if
test=
"record.refundTime != null"
>
refund_time = #{record.refundTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"record.confirmTime != null"
>
confirm_time = #{record.confirmTime,jdbcType=TIMESTAMP},
</if>
...
...
@@ -537,6 +579,10 @@
ship_sn = #{record.shipSn,jdbcType=VARCHAR},
ship_channel = #{record.shipChannel,jdbcType=VARCHAR},
ship_time = #{record.shipTime,jdbcType=TIMESTAMP},
refund_amount = #{record.refundAmount,jdbcType=DECIMAL},
refund_type = #{record.refundType,jdbcType=VARCHAR},
refund_content = #{record.refundContent,jdbcType=VARCHAR},
refund_time = #{record.refundTime,jdbcType=TIMESTAMP},
confirm_time = #{record.confirmTime,jdbcType=TIMESTAMP},
comments = #{record.comments,jdbcType=SMALLINT},
end_time = #{record.endTime,jdbcType=TIMESTAMP},
...
...
@@ -611,6 +657,18 @@
<if
test=
"shipTime != null"
>
ship_time = #{shipTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"refundAmount != null"
>
refund_amount = #{refundAmount,jdbcType=DECIMAL},
</if>
<if
test=
"refundType != null"
>
refund_type = #{refundType,jdbcType=VARCHAR},
</if>
<if
test=
"refundContent != null"
>
refund_content = #{refundContent,jdbcType=VARCHAR},
</if>
<if
test=
"refundTime != null"
>
refund_time = #{refundTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"confirmTime != null"
>
confirm_time = #{confirmTime,jdbcType=TIMESTAMP},
</if>
...
...
@@ -657,6 +715,10 @@
ship_sn = #{shipSn,jdbcType=VARCHAR},
ship_channel = #{shipChannel,jdbcType=VARCHAR},
ship_time = #{shipTime,jdbcType=TIMESTAMP},
refund_amount = #{refundAmount,jdbcType=DECIMAL},
refund_type = #{refundType,jdbcType=VARCHAR},
refund_content = #{refundContent,jdbcType=VARCHAR},
refund_time = #{refundTime,jdbcType=TIMESTAMP},
confirm_time = #{confirmTime,jdbcType=TIMESTAMP},
comments = #{comments,jdbcType=SMALLINT},
end_time = #{endTime,jdbcType=TIMESTAMP},
...
...
Write
Preview
Supports
Markdown
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