记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
Project
Project
Details
Activity
Releases
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
董敬伟
liquidnet-bus-v1
Commits
f4cdcbc7
Commit
f4cdcbc7
authored
Jun 04, 2021
by
jiangxiulong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refundBatch
parent
e7666c03
Changes
14
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
467 additions
and
291 deletions
+467
-291
RefundApplyParam.java
...m/liquidnet/service/kylin/dto/param/RefundApplyParam.java
+0
-3
RefundBatchApplyParam.java
...uidnet/service/kylin/dto/param/RefundBatchApplyParam.java
+32
-0
RefundBatchSearchParam.java
...idnet/service/kylin/dto/param/RefundBatchSearchParam.java
+36
-0
KylinOrderRefundBatchAdminController.java
.../zhengzai/kylin/KylinOrderRefundBatchAdminController.java
+75
-141
refund.html
...ain/resources/templates/zhengzai/kylin/refund/refund.html
+0
-1
details.html
...sources/templates/zhengzai/kylin/refundBatch/details.html
+23
-0
refundBatch.html
...ces/templates/zhengzai/kylin/refundBatch/refundBatch.html
+214
-0
KylinOrderRefundsServiceImpl.java
...gzai/kylin/service/impl/KylinOrderRefundsServiceImpl.java
+0
-1
KylinRefundExecuteServiceImpl.java
...zai/kylin/service/impl/KylinRefundExecuteServiceImpl.java
+55
-18
KylinRefundHttpSubmitServiceImpl.java
.../kylin/service/impl/KylinRefundHttpSubmitServiceImpl.java
+0
-101
KylinRefundPerformancesAdminServiceImpl.java
...service/impl/KylinRefundPerformancesAdminServiceImpl.java
+30
-23
KylinOrderRefundBatches.java
...quidnet/service/kylin/entity/KylinOrderRefundBatches.java
+0
-1
KylinOrderTicketsMapper.java
...quidnet/service/kylin/mapper/KylinOrderTicketsMapper.java
+1
-1
KylinOrderTicketsMapper.xml
...iquidnet.service.kylin.mapper/KylinOrderTicketsMapper.xml
+1
-1
No files found.
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/param/RefundApplyParam.java
View file @
f4cdcbc7
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
param
;
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
param
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
import
javax.validation.constraints.NotNull
;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
java.util.List
;
import
java.util.List
;
...
...
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/param/RefundBatchApplyParam.java
0 → 100644
View file @
f4cdcbc7
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
param
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* <p>
* 退款申请参数
* </p>
*
* @author jiangxiulong
* @since 2021-06-02 11:19 上午
*/
@Data
public
class
RefundBatchApplyParam
implements
Serializable
{
private
String
targetId
;
private
String
refundBatchId
;
private
String
reason
;
private
Integer
status
;
private
Integer
refundStatus
;
private
String
reject
;
private
String
refuse
;
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/param/RefundBatchSearchParam.java
0 → 100644
View file @
f4cdcbc7
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
param
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
javax.validation.constraints.NotNull
;
import
java.io.Serializable
;
/**
* <p>
* 退款回掉参数
* </p>
*
* @author jiangxiulong
* @since 2021-05-31 11:19 上午
*/
@Data
public
class
RefundBatchSearchParam
implements
Serializable
{
private
String
refundBatchId
;
private
String
targetId
;
private
Integer
status
;
private
String
createdAt
;
@ApiModelProperty
(
value
=
"页数"
,
example
=
"0"
)
@NotNull
(
message
=
"不能为空"
)
private
Integer
pageSize
;
@ApiModelProperty
(
value
=
"数量"
,
example
=
"20"
)
@NotNull
(
message
=
"不能为空"
)
private
Integer
pageNum
;
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/kylin/KylinOrderRefundBatchAdminController.java
View file @
f4cdcbc7
This diff is collapsed.
Click to expand it.
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/kylin/refund/refund.html
View file @
f4cdcbc7
...
@@ -109,7 +109,6 @@
...
@@ -109,7 +109,6 @@
</div>
</div>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: footer"
/>
{include file="zhengzai/kylin/refund/reviewView.html" /}
<script
th:inline=
"javascript"
>
<script
th:inline=
"javascript"
>
var
detailFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refund:detail'
)}]];
var
detailFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refund:detail'
)}]];
var
reviewFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refund:review'
)}]];
var
reviewFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refund:review'
)}]];
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/kylin/refundBatch/details.html
0 → 100644
View file @
f4cdcbc7
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<th:block
th:include=
"include :: header('演出退款详情')"
/>
</head>
<body
class=
"white-bg"
>
<div
class=
"wrapper wrapper-content animated fadeInRight ibox-content"
>
<form
class=
"form-horizontal m-t"
id=
"signupForm"
>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
批量退款id:
</label>
<div
class=
"form-control-static"
th:text=
"${KylinOrderRefundsBatchVo.refundBatchId}"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
批量提交时间:
</label>
<div
class=
"form-control-static"
th:text=
"${KylinOrderRefundsBatchVo.createdAt}"
>
</div>
</div>
</form>
</div>
<th:block
th:include=
"include :: footer"
/>
</body>
</html>
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/kylin/refundBatch/refundBatch.html
0 → 100644
View file @
f4cdcbc7
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
xmlns:shiro=
"http://www.pollix.at/thymeleaf/shiro"
>
<head>
<th:block
th:include=
"include :: header('演出退款列表')"
/>
</head>
<body
class=
"gray-bg"
>
<div
class=
"container-div"
>
<div
class=
"row"
>
<div
class=
"col-sm-12 search-collapse"
>
<form
id=
"formId"
>
<div
class=
"select-list"
>
<ul>
<li>
<label>
退款Id:
</label>
<input
type=
"text"
name=
"refundBatchId"
/>
</li>
<li>
<label>
演出Id:
</label>
<input
type=
"text"
name=
"targetId"
/>
</li>
<li>
<label>
退款状态:
</label>
<select
name=
"status"
>
<option
value=
""
>
全部
</option>
<option
value=
"1"
>
申请退款
</option>
<option
value=
"2"
>
取消退款
</option>
<option
value=
"3"
>
运营驳回审核
</option>
<option
value=
"4"
>
运营通过审核
</option>
<option
value=
"5"
>
财务驳回审核
</option>
<option
value=
"6"
>
财务通过审核
</option>
</select>
</li>
<li>
<a
class=
"btn btn-primary btn-rounded btn-sm"
onclick=
"$.table.search()"
><i
class=
"fa fa-search"
></i>
搜索
</a>
<a
class=
"btn btn-warning btn-rounded btn-sm"
onclick=
"$.form.reset()"
><i
class=
"fa fa-refresh"
></i>
重置
</a>
</li>
</ul>
</div>
</form>
</div>
<div
class=
"btn-group-sm"
id=
"toolbar"
role=
"group"
>
<a
class=
"btn btn-success"
onclick=
"apply()"
shiro:hasPermission=
"kylin:refundBatch:apply"
>
添加
</a>
</div>
<div
class=
"col-sm-12 select-table table-bordered"
>
<table
id=
"bootstrap-table"
></table>
</div>
<form
id=
"appTest"
>
<div
class=
"select-list"
>
<ul>
<li>
<input
type=
"text"
name=
"targetId"
th:value=
"67689474263547904"
/>
<input
type=
"text"
name=
"reason"
th:value=
"222"
/>
</li>
</ul>
</div>
</form>
<div
class=
"wrapper wrapper-content animated fadeInRight ibox-content hidden"
id=
"form-refund-review"
>
<form
class=
"form-horizontal m"
>
<div
class=
"row"
>
<div
class=
"col-sm-12"
>
<div
class=
"form-group"
>
<label
class=
"col-xs-2 control-label layui-required"
>
备注:
</label>
<div
class=
"col-xs-10"
>
<textarea
name=
"remark"
maxlength=
"500"
class=
"form-control layui-required"
rows=
"3"
></textarea>
</div>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<script
th:inline=
"javascript"
>
var
detailFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refundBatch:detail'
)}]];
var
reviewFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refundBatch:review'
)}]];
var
executeFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refundBatch:execute'
)}]];
var
cancelFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refundBatch:cancel'
)}]];
var
reapplyFlag
=
[[
$
{@
permission
.
hasPermi
(
'kylin:refundBatch:reapply'
)}]];
var
prefix
=
ctx
+
"kylin/refundBatch"
;
function
apply
()
{
var
data
=
$
(
'#appTest'
).
serializeArray
();
$
.
operate
.
save
(
prefix
+
"/apply"
,
data
);
}
function
review
(
id
)
{
data
=
{
"refundBatchId"
:
id
};
layer
.
open
({
type
:
1
,
fixed
:
false
,
maxmin
:
true
,
title
:
'一审'
,
area
:
[
'500px'
,
'220px'
],
content
:
$
(
"#form-refund-review"
).
html
(),
btn
:
[
"通过"
,
'拒绝'
],
yes
:
function
(
index
,
layero
)
{
var
remark
=
$
(
layero
).
find
(
"[name='remark']"
).
val
();
if
(
!
remark
)
{
layer
.
msg
(
"请填写备注"
);
return
false
;
}
data
[
'reject'
]
=
remark
;
data
[
'status'
]
=
1
;
$
.
operate
.
save
(
prefix
+
"/review"
,
data
);
layer
.
close
(
index
)
},
btn2
:
function
(
index
,
layero
)
{
var
remark
=
$
(
layero
).
find
(
"[name='remark']"
).
val
();
if
(
!
remark
)
{
layer
.
msg
(
"请填写备注"
);
return
false
;
}
data
[
'reject'
]
=
remark
;
data
[
'status'
]
=
5
;
$
.
operate
.
save
(
prefix
+
"/review"
,
data
);
}
});
}
function
execute
(
id
)
{
data
=
{
"refundBatchId"
:
id
};
layer
.
open
({
type
:
1
,
fixed
:
false
,
maxmin
:
true
,
title
:
'二审'
,
area
:
[
'500px'
,
'220px'
],
content
:
$
(
"#form-refund-review"
).
html
(),
btn
:
[
"通过"
,
'拒绝'
],
yes
:
function
(
index
,
layero
)
{
var
remark
=
$
(
layero
).
find
(
"[name='remark']"
).
val
();
if
(
!
remark
)
{
layer
.
msg
(
"请填写备注"
);
return
false
;
}
data
[
'refuse'
]
=
remark
;
data
[
'status'
]
=
7
;
$
.
operate
.
save
(
prefix
+
"/execute"
,
data
);
layer
.
close
(
index
)
},
btn2
:
function
(
index
,
layero
)
{
var
remark
=
$
(
layero
).
find
(
"[name='remark']"
).
val
();
if
(
!
remark
)
{
layer
.
msg
(
"请填写备注"
);
return
false
;
}
data
[
'refuse'
]
=
remark
;
data
[
'status'
]
=
8
;
$
.
operate
.
save
(
prefix
+
"/execute"
,
data
);
// return false;
}
});
}
$
(
function
()
{
var
options
=
{
url
:
prefix
+
"/list"
,
detailUrl
:
prefix
+
"/details/{id}"
,
cancelUrl
:
prefix
+
"/cancel"
,
reapplyUrl
:
prefix
+
"/reapply"
,
columns
:
[{
checkbox
:
true
},
{
field
:
'refundBatchId'
,
title
:
'退款id'
},
{
field
:
'status'
,
title
:
'状态'
},
{
field
:
'targetId'
,
title
:
'演出id'
},
{
field
:
'createdAt'
,
title
:
'申请时间'
},
{
title
:
'操作'
,
align
:
'center'
,
formatter
:
function
(
value
,
row
,
index
)
{
var
actions
=
[];
actions
.
push
(
'<a class="btn btn-info btn-xs'
+
detailFlag
+
'" href="javascript:void(0)" onclick="$.operate.detailTab(
\'
'
+
row
.
refundBatchId
+
'
\'
)"></i>查看</a> '
);
actions
.
push
(
'<a class="btn btn-success btn-xs '
+
reviewFlag
+
'" href="javascript:void(0)" onclick="review(
\'
'
+
row
.
refundBatchId
+
'
\'
)"></i>一审</a> '
);
actions
.
push
(
'<a class="btn btn-primary btn-xs '
+
executeFlag
+
'" href="javascript:void(0)" onclick="execute(
\'
'
+
row
.
refundBatchId
+
'
\'
)"></i>二审</a> '
);
actions
.
push
(
'<a class="btn btn-danger btn-xs '
+
cancelFlag
+
'" href="javascript:void(0)" onclick="$.operate.remove(
\'
'
+
row
.
refundBatchId
+
'
\'
,
\'
确定取消退款申请吗?
\'
, table.options.cancelUrl)"></i>取消</a> '
);
actions
.
push
(
'<a class="btn btn-warning btn-xs '
+
reapplyFlag
+
'" href="javascript:void(0)" onclick="$.operate.remove(
\'
'
+
row
.
refundBatchId
+
'
\'
,
\'
确定重新提交退款审核吗?
\'
, table.options.reapplyUrl)"></i>重新提交</a> '
);
return
actions
.
join
(
''
);
}
}]
};
$
.
table
.
init
(
options
);
});
</script>
</body>
</html>
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinOrderRefundsServiceImpl.java
View file @
f4cdcbc7
...
@@ -5,7 +5,6 @@ import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
...
@@ -5,7 +5,6 @@ import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.client.admin.common.utils.ShiroUtils
;
import
com.liquidnet.client.admin.zhengzai.kylin.utils.DataUtils
;
import
com.liquidnet.client.admin.zhengzai.kylin.utils.DataUtils
;
import
com.liquidnet.commons.lang.util.BeanUtil
;
import
com.liquidnet.commons.lang.util.BeanUtil
;
import
com.liquidnet.service.kylin.constant.KylinTableStatusConst
;
import
com.liquidnet.service.kylin.constant.KylinTableStatusConst
;
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinRefundExecuteServiceImpl.java
View file @
f4cdcbc7
...
@@ -3,6 +3,8 @@ package com.liquidnet.client.admin.zhengzai.kylin.service.impl;
...
@@ -3,6 +3,8 @@ package com.liquidnet.client.admin.zhengzai.kylin.service.impl;
import
com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper
;
import
com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper
;
import
com.liquidnet.common.cache.redis.util.RedisUtil
;
import
com.liquidnet.common.cache.redis.util.RedisUtil
;
import
com.liquidnet.service.kylin.constant.KylinTableStatusConst
;
import
com.liquidnet.service.kylin.constant.KylinTableStatusConst
;
import
com.liquidnet.service.kylin.dto.param.RefundApplyParam
;
import
com.liquidnet.service.kylin.dto.param.RefundBatchApplyParam
;
import
com.liquidnet.service.kylin.entity.KylinOrderRefunds
;
import
com.liquidnet.service.kylin.entity.KylinOrderRefunds
;
import
com.liquidnet.service.kylin.entity.KylinOrderTicketEntities
;
import
com.liquidnet.service.kylin.entity.KylinOrderTicketEntities
;
import
com.liquidnet.service.kylin.entity.KylinOrderTickets
;
import
com.liquidnet.service.kylin.entity.KylinOrderTickets
;
...
@@ -13,8 +15,8 @@ import org.springframework.beans.factory.annotation.Autowired;
...
@@ -13,8 +15,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.stream.Collectors
;
/**
/**
* <p>
* <p>
...
@@ -40,23 +42,30 @@ public class KylinRefundExecuteServiceImpl {
...
@@ -40,23 +42,30 @@ public class KylinRefundExecuteServiceImpl {
RedisUtil
redisUtil
;
RedisUtil
redisUtil
;
@Autowired
@Autowired
private
Kylin
RefundHttpSubmitServiceImpl
kylinRefundHttpSubmit
ServiceImpl
;
private
Kylin
OrderRefundsServiceImpl
kylinOrderRefunds
ServiceImpl
;
@Async
@Async
public
void
refundBatchApply
(
String
targetId
,
String
refundBatchId
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
public
void
refundBatchApply
(
String
targetId
,
String
refundBatchId
,
String
reason
)
throws
Exception
{
RefundApplyParam
refundApplyParam
=
new
RefundApplyParam
();
int
count
;
int
count
;
int
limitNum
=
100
;
int
limitNum
=
100
;
int
mid
=
0
;
int
mid
=
0
;
do
{
do
{
List
<
KylinOrderTickets
>
orderList
=
kylinOrderTicketsMapper
.
getOrder
Entities
(
targetId
,
mid
,
limitNum
);
List
<
KylinOrderTickets
>
orderList
=
kylinOrderTicketsMapper
.
getOrder
List
(
targetId
,
mid
,
limitNum
);
for
(
KylinOrderTickets
v
:
orderList
)
{
for
(
KylinOrderTickets
order
:
orderList
)
{
List
<
KylinOrderTicketEntities
>
entitiesList
=
kylinOrderTicketEntitiesMapper
.
selectList
(
List
<
KylinOrderTicketEntities
>
entitiesList
=
kylinOrderTicketEntitiesMapper
.
selectList
(
new
UpdateWrapper
<
KylinOrderTicketEntities
>().
eq
(
"order_id"
,
v
.
getOrderTicketsId
())
new
UpdateWrapper
<
KylinOrderTicketEntities
>().
eq
(
"order_id"
,
order
.
getOrderTicketsId
())
.
eq
(
"is_payment"
,
"yes"
)
.
eq
(
"is_payment"
,
"yes"
)
);
);
List
<
String
>
ticketEntityIds
=
entitiesList
.
stream
().
map
(
KylinOrderTicketEntities
->
KylinOrderTicketEntities
.
getOrderTicketEntitiesId
()).
collect
(
Collectors
.
toList
());
// 请求php接口
// 请求php接口
kylinRefundHttpSubmitServiceImpl
.
httpApply
(
v
,
entitiesList
,
otherParam
,
refundBatchId
);
refundApplyParam
.
setOrderRefundBatchesId
(
refundBatchId
);
refundApplyParam
.
setReason
(
reason
);
refundApplyParam
.
setOrderTicketsId
(
order
.
getOrderTicketsId
());
refundApplyParam
.
setTicketEntityIds
(
ticketEntityIds
);
refundApplyParam
.
setRefundPriceExpress
(
order
.
getPriceExpress
().
doubleValue
());
Boolean
res
=
kylinOrderRefundsServiceImpl
.
refundApply
(
refundApplyParam
);
}
}
count
=
orderList
.
size
();
count
=
orderList
.
size
();
...
@@ -66,11 +75,13 @@ public class KylinRefundExecuteServiceImpl {
...
@@ -66,11 +75,13 @@ public class KylinRefundExecuteServiceImpl {
}
}
@Async
@Async
public
void
refundBatchStatus
(
String
refundBatchId
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
public
void
refundBatchStatus
(
RefundBatchApplyParam
refundBatchApplyParam
,
String
type
)
throws
Exception
{
String
refundBatchId
=
refundBatchApplyParam
.
getRefundBatchId
();
Integer
status
=
refundBatchApplyParam
.
getStatus
();
// 处理查询订单状态
// 处理查询订单状态
Integer
[]
whereStatus
=
{};
Integer
[]
whereStatus
=
{};
Integer
whereType
=
KylinTableStatusConst
.
ORDER_REFUND_TYPE_APPLY
;
Integer
whereType
=
KylinTableStatusConst
.
ORDER_REFUND_TYPE_APPLY
;
switch
(
(
String
)
otherParam
.
get
(
"type"
)
)
{
switch
(
type
)
{
case
"reapply"
:
case
"reapply"
:
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
break
;
break
;
...
@@ -78,18 +89,18 @@ public class KylinRefundExecuteServiceImpl {
...
@@ -78,18 +89,18 @@ public class KylinRefundExecuteServiceImpl {
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPLY
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPLY
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
break
;
break
;
case
"review"
:
case
"review"
:
if
(
otherParam
.
get
(
"status"
)
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
)
{
// 通过申请
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
)
{
// 通过申请
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPLY
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPLY
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
}
}
if
(
otherParam
.
get
(
"status"
)
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
)
{
// 驳回申请
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
)
{
// 驳回申请
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPLY
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPLY
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
};
}
}
break
;
break
;
case
"execute"
:
case
"execute"
:
if
(
otherParam
.
get
(
"status"
)
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_UNFILLED
)
{
// 执行退款
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_UNFILLED
)
{
// 执行退款
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_ERROR
};
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_ERROR
};
}
}
if
(
otherParam
.
get
(
"status"
)
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
)
{
// 拒绝退款
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
)
{
// 拒绝退款
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_ERROR
};
whereStatus
=
new
Integer
[]{
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
,
KylinTableStatusConst
.
ORDER_REFUND_STATUS_ERROR
};
}
}
break
;
break
;
...
@@ -105,12 +116,38 @@ public class KylinRefundExecuteServiceImpl {
...
@@ -105,12 +116,38 @@ public class KylinRefundExecuteServiceImpl {
List
<
String
>
refundIds
=
null
;
List
<
String
>
refundIds
=
null
;
if
(!
refundList
.
isEmpty
())
{
if
(!
refundList
.
isEmpty
())
{
for
(
KylinOrderRefunds
v
:
refundList
)
{
refundIds
=
refundList
.
stream
().
map
(
KylinOrderRefunds
->
KylinOrderRefunds
.
getOrderRefundsId
()).
collect
(
Collectors
.
toList
());
String
refundId
=
v
.
getRefundId
();
refundIds
.
add
(
refundId
);
RefundApplyParam
refundApplyParam
=
new
RefundApplyParam
();
refundApplyParam
.
setIds
(
refundIds
);
Boolean
res
=
null
;
switch
(
type
)
{
case
"reapply"
:
res
=
kylinOrderRefundsServiceImpl
.
refundReapply
(
refundApplyParam
);
break
;
case
"cancel"
:
res
=
kylinOrderRefundsServiceImpl
.
refundCancel
(
refundApplyParam
);
break
;
case
"review"
:
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_APPROVED
)
{
// 通过申请
res
=
kylinOrderRefundsServiceImpl
.
refundApproved
(
refundApplyParam
);
}
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
)
{
// 驳回申请
res
=
kylinOrderRefundsServiceImpl
.
refundReject
(
refundApplyParam
);
}
break
;
case
"execute"
:
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_UNFILLED
)
{
// 执行退款
res
=
kylinOrderRefundsServiceImpl
.
refundUnfilled
(
refundApplyParam
);
}
if
(
status
==
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
)
{
// 拒绝退款
res
=
kylinOrderRefundsServiceImpl
.
refundRefuse
(
refundApplyParam
);
}
break
;
default
:
throw
new
Exception
(
"type异常,无法操作"
);
}
}
// 请求php接口
kylinRefundHttpSubmitServiceImpl
.
httpStatus
(
refundIds
,
otherParam
);
}
}
count
=
refundList
.
size
();
count
=
refundList
.
size
();
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinRefundHttpSubmitServiceImpl.java
deleted
100644 → 0
View file @
e7666c03
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
com.fasterxml.jackson.databind.JsonNode
;
import
com.liquidnet.commons.lang.util.HttpUtil
;
import
com.liquidnet.commons.lang.util.JsonUtils
;
import
com.liquidnet.service.kylin.entity.KylinOrderTicketEntities
;
import
com.liquidnet.service.kylin.entity.KylinOrderTickets
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.LinkedMultiValueMap
;
import
org.springframework.util.MultiValueMap
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* <p>
* 后台退款 服务实现类
* </p>
*
* @author jiangxiulong
* @since 2021-05-26 13:00 下午
*/
@Service
public
class
KylinRefundHttpSubmitServiceImpl
{
@Async
public
void
httpApply
(
KylinOrderTickets
orderInfo
,
List
<
KylinOrderTicketEntities
>
entitiesList
,
HashMap
<
String
,
Object
>
otherParam
,
String
refundBatchId
)
throws
Exception
{
String
postUrl
=
"apply"
;
// 构造退款数据
List
<
String
>
ticketEntityIds
=
null
;
if
(!
entitiesList
.
isEmpty
())
{
for
(
KylinOrderTicketEntities
v
:
entitiesList
)
{
String
orderTicketsId
=
v
.
getOrderTicketEntitiesId
();
ticketEntityIds
.
add
(
orderTicketsId
);
}
}
HashMap
<
String
,
Object
>
refundData
=
new
HashMap
();
refundData
.
put
(
"ticket_entity_ids"
,
ticketEntityIds
);
refundData
.
put
(
"matter_items"
,
new
ArrayList
());
//搭售不处理
if
(
ticketEntityIds
.
isEmpty
())
{
throw
new
Exception
(
"查询详情出错"
);
}
// 发起退款申请
MultiValueMap
<
String
,
String
>
headers
=
new
LinkedMultiValueMap
();
headers
.
add
(
"Authorization"
,
otherParam
.
get
(
"token"
).
toString
());
MultiValueMap
<
String
,
String
>
formParams
=
new
LinkedMultiValueMap
();
formParams
.
add
(
"order_type"
,
"order_ticket"
);
formParams
.
add
(
"order_id"
,
orderInfo
.
getOrderTicketsId
());
formParams
.
add
(
"batch_id"
,
refundBatchId
);
formParams
.
add
(
"reason"
,
otherParam
.
get
(
"reason"
).
toString
());
formParams
.
add
(
"refund_data"
,
JsonUtils
.
toJson
(
refundData
));
/*HashMap<String, Object> postParams = new HashMap();
postParams.put("headers", headers);
postParams.put("form_params", formParams);*/
// 请求提审接口参数
String
postResult
=
HttpUtil
.
post
(
postUrl
,
formParams
,
headers
);
JsonNode
postResultNew
=
JsonUtils
.
fromJson
(
postResult
,
JsonNode
.
class
);
// 请求提审接口结果
if
(
postResultNew
.
get
(
"message"
).
toString
()
!=
"OK"
)
{
throw
new
Exception
(
"申请退款出错"
);
}
}
@Async
public
void
httpStatus
(
List
<
String
>
refundIds
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
String
postUrl
=
"reapply"
;
// 发起退款申请
MultiValueMap
<
String
,
String
>
headers
=
new
LinkedMultiValueMap
();
headers
.
add
(
"Authorization"
,
otherParam
.
get
(
"token"
).
toString
());
MultiValueMap
<
String
,
String
>
formParams
=
new
LinkedMultiValueMap
();
formParams
.
put
(
"ids"
,
refundIds
);
String
reject
=
otherParam
.
get
(
"reject"
).
toString
();
if
(
reject
.
isEmpty
())
reject
=
""
;
String
refuse
=
otherParam
.
get
(
"refuse"
).
toString
();
if
(
refuse
.
isEmpty
())
refuse
=
""
;
String
status
=
(
String
)
otherParam
.
get
(
"status"
);
if
(
status
.
isEmpty
())
status
=
"0"
;
formParams
.
add
(
"reject"
,
reject
);
formParams
.
add
(
"status"
,
status
);
formParams
.
add
(
"refuse"
,
refuse
);
// 请求提审接口参数
String
postResult
=
HttpUtil
.
post
(
postUrl
,
formParams
,
headers
);
JsonNode
postResultNew
=
JsonUtils
.
fromJson
(
postResult
,
JsonNode
.
class
);
// 请求提审接口结果
if
(
postResultNew
.
get
(
"message"
).
toString
()
!=
"OK"
)
{
throw
new
Exception
(
"操作出错"
);
}
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinRefundPerformancesAdminServiceImpl.java
View file @
f4cdcbc7
...
@@ -8,6 +8,8 @@ import com.liquidnet.commons.lang.util.IDGenerator;
...
@@ -8,6 +8,8 @@ import com.liquidnet.commons.lang.util.IDGenerator;
import
com.liquidnet.service.kylin.constant.KylinRedisConst
;
import
com.liquidnet.service.kylin.constant.KylinRedisConst
;
import
com.liquidnet.service.kylin.constant.KylinTableStatusConst
;
import
com.liquidnet.service.kylin.constant.KylinTableStatusConst
;
import
com.liquidnet.service.kylin.dao.OrderRefundBatchDao
;
import
com.liquidnet.service.kylin.dao.OrderRefundBatchDao
;
import
com.liquidnet.service.kylin.dto.param.RefundBatchApplyParam
;
import
com.liquidnet.service.kylin.dto.param.RefundBatchSearchParam
;
import
com.liquidnet.service.kylin.dto.vo.KylinOrderRefundBatchesVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinOrderRefundBatchesVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinPerformanceVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinPerformanceVo
;
import
com.liquidnet.service.kylin.entity.KylinOrderRefundBatches
;
import
com.liquidnet.service.kylin.entity.KylinOrderRefundBatches
;
...
@@ -46,25 +48,28 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -46,25 +48,28 @@ public class KylinRefundPerformancesAdminServiceImpl {
@Autowired
@Autowired
RedisUtil
redisUtil
;
RedisUtil
redisUtil
;
public
Boolean
refundBatchApply
(
String
targetId
,
Integer
targetType
,
Integer
authId
,
String
authName
,
HashMap
<
String
,
Object
>
OtherParam
)
throws
Exception
{
public
Boolean
refundBatchApply
(
RefundBatchApplyParam
refundBatchApplyParam
)
throws
Exception
{
String
targetId
=
refundBatchApplyParam
.
getTargetId
();
HashMap
<
String
,
Object
>
priceNum
=
kylinOrderTicketsMapper
.
getPriceNum
(
targetId
);
HashMap
<
String
,
Object
>
priceNum
=
kylinOrderTicketsMapper
.
getPriceNum
(
targetId
);
Double
totalPrice
=
(
Double
)
priceNum
.
get
(
"total_price"
);
Double
totalPrice
=
(
Double
)
priceNum
.
get
(
"total_price"
);
Integer
totalNum
=
(
Integer
)
priceNum
.
get
(
"total_num"
);
Integer
totalNum
=
(
Integer
)
priceNum
.
get
(
"total_num"
);
if
(
totalPrice
<
0
||
totalNum
<
0
)
throw
new
Exception
(
"当前演出暂无需要退款的订单,请确认后重试!"
);
if
(
totalPrice
<
0
||
totalNum
<
0
)
throw
new
Exception
(
"当前演出暂无需要退款的订单,请确认后重试!"
);
// 汇总退款
// 汇总退款
String
[]
paymentTypeAlipayArray
=
{
"APPALIPAY"
,
"WAPALIPAY"
,
"alipay"
};
/*
String[] paymentTypeAlipayArray = {"APPALIPAY", "WAPALIPAY", "alipay"};
double totalRefundAlipay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_actual", paymentTypeAlipayArray);
double totalRefundAlipay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_actual", paymentTypeAlipayArray);
String[] paymentTypeWepayArray = {"APPWEPAY", "APPLETWEPAY", "WAPWEPAY", "JSWEPAY", "wepay"};
String[] paymentTypeWepayArray = {"APPWEPAY", "APPLETWEPAY", "WAPWEPAY", "JSWEPAY", "wepay"};
double totalRefundWepay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_actual", paymentTypeWepayArray);
double totalRefundWepay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_actual", paymentTypeWepayArray);
double totalPriceExpressAlipay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_express", paymentTypeAlipayArray);
double totalPriceExpressAlipay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_express", paymentTypeAlipayArray);
double
totalPriceExpressWepay
=
kylinOrderTicketsMapper
.
getTotalPrice
(
targetId
,
"price_express"
,
paymentTypeWepayArray
);
double totalPriceExpressWepay = kylinOrderTicketsMapper.getTotalPrice(targetId, "price_express", paymentTypeWepayArray);
*/
KylinOrderRefundBatches
refundBatchesInfo
=
kylinOrderRefundBatchesMapper
.
selectOne
(
KylinOrderRefundBatches
refundBatchesInfo
=
kylinOrderRefundBatchesMapper
.
selectOne
(
new
UpdateWrapper
<
KylinOrderRefundBatches
>().
eq
(
"target_id"
,
targetId
).
eq
(
"target_type"
,
targetType
).
orderByDesc
(
"refund_batch_id"
)
new
UpdateWrapper
<
KylinOrderRefundBatches
>().
eq
(
"target_id"
,
targetId
).
orderByDesc
(
"refund_batch_id"
)
);
);
if
(
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
()
||
refundBatchesInfo
.
getStatus
()
==
KylinTableStatusConst
.
STATUS_CANCEL
||
refundBatchesInfo
.
getStatus
()
==
KylinTableStatusConst
.
STATUS_FINANCE_ADOPT
)
{
if
(
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
()
||
refundBatchesInfo
.
getStatus
()
==
KylinTableStatusConst
.
STATUS_CANCEL
||
refundBatchesInfo
.
getStatus
()
==
KylinTableStatusConst
.
STATUS_FINANCE_ADOPT
)
{
// 添加演出退款记录
// 添加演出退款记录
KylinPerformanceVo
performancesInfo
=
(
KylinPerformanceVo
)
redisUtil
.
hget
(
KylinRedisConst
.
PERFORMANCES
,
targetId
);
KylinPerformanceVo
performancesInfo
=
(
KylinPerformanceVo
)
redisUtil
.
hget
(
KylinRedisConst
.
PERFORMANCES
,
targetId
);
String
refundBatchId
=
IDGenerator
.
nextSnowId
().
toString
();
String
refundBatchId
=
IDGenerator
.
nextSnowId
().
toString
();
...
@@ -76,7 +81,7 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -76,7 +81,7 @@ public class KylinRefundPerformancesAdminServiceImpl {
int
resNum
=
kylinOrderRefundBatchesMapper
.
insert
(
createData
);
int
resNum
=
kylinOrderRefundBatchesMapper
.
insert
(
createData
);
if
(
resNum
>
0
)
{
if
(
resNum
>
0
)
{
// 开始执行批量提交审核 分批处理退款申请
// 开始执行批量提交审核 分批处理退款申请
kylinRefundExecuteServiceImpl
.
refundBatchApply
(
targetId
,
refundBatchId
,
OtherParam
);
kylinRefundExecuteServiceImpl
.
refundBatchApply
(
targetId
,
refundBatchId
,
refundBatchApplyParam
.
getReason
()
);
return
true
;
return
true
;
}
else
{
}
else
{
return
false
;
return
false
;
...
@@ -86,15 +91,15 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -86,15 +91,15 @@ public class KylinRefundPerformancesAdminServiceImpl {
}
}
}
}
public
Boolean
refundBatchReapply
(
String
refundBatchId
,
String
remark
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
public
Boolean
refundBatchReapply
(
RefundBatchApplyParam
refundBatchApplyParam
)
throws
Exception
{
String
refundBatchId
=
refundBatchApplyParam
.
getRefundBatchId
();
Integer
[]
paymentTypeAlipayArray
=
{
KylinTableStatusConst
.
STATUS_OPERATE_REJECT
,
KylinTableStatusConst
.
STATUS_FINANCE_REJECT
};
Integer
[]
paymentTypeAlipayArray
=
{
KylinTableStatusConst
.
STATUS_OPERATE_REJECT
,
KylinTableStatusConst
.
STATUS_FINANCE_REJECT
};
KylinOrderRefundBatches
refundBatchesInfo
=
kylinOrderRefundBatchesMapper
.
selectOne
(
KylinOrderRefundBatches
refundBatchesInfo
=
kylinOrderRefundBatchesMapper
.
selectOne
(
new
UpdateWrapper
<
KylinOrderRefundBatches
>().
eq
(
"refund_batch_id"
,
refundBatchId
).
in
(
"status"
,
paymentTypeAlipayArray
)
new
UpdateWrapper
<
KylinOrderRefundBatches
>().
eq
(
"refund_batch_id"
,
refundBatchId
).
in
(
"status"
,
paymentTypeAlipayArray
)
);
);
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
// 开始执行批量提交审核 分批处理退款申请
// 开始执行批量提交审核 分批处理退款申请
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
Id
,
otherParam
);
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
ApplyParam
,
"reapply"
);
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
params
.
setStatus
(
KylinTableStatusConst
.
STATUS_APPLY
);
params
.
setStatus
(
KylinTableStatusConst
.
STATUS_APPLY
);
...
@@ -106,15 +111,15 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -106,15 +111,15 @@ public class KylinRefundPerformancesAdminServiceImpl {
}
}
}
}
public
Boolean
refundBatchCancel
(
String
refundBatchId
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
public
Boolean
refundBatchCancel
(
RefundBatchApplyParam
refundBatchApplyParam
)
throws
Exception
{
String
refundBatchId
=
refundBatchApplyParam
.
getRefundBatchId
();
Integer
[]
paymentTypeAlipayArray
=
{
KylinTableStatusConst
.
STATUS_APPLY
,
KylinTableStatusConst
.
STATUS_OPERATE_REJECT
,
KylinTableStatusConst
.
STATUS_OPERATE_ADOPT
,
KylinTableStatusConst
.
STATUS_FINANCE_REJECT
};
Integer
[]
paymentTypeAlipayArray
=
{
KylinTableStatusConst
.
STATUS_APPLY
,
KylinTableStatusConst
.
STATUS_OPERATE_REJECT
,
KylinTableStatusConst
.
STATUS_OPERATE_ADOPT
,
KylinTableStatusConst
.
STATUS_FINANCE_REJECT
};
KylinOrderRefundBatches
refundBatchesInfo
=
kylinOrderRefundBatchesMapper
.
selectOne
(
KylinOrderRefundBatches
refundBatchesInfo
=
kylinOrderRefundBatchesMapper
.
selectOne
(
new
UpdateWrapper
<
KylinOrderRefundBatches
>().
eq
(
"refund_batch_id"
,
refundBatchId
).
in
(
"status"
,
paymentTypeAlipayArray
)
new
UpdateWrapper
<
KylinOrderRefundBatches
>().
eq
(
"refund_batch_id"
,
refundBatchId
).
in
(
"status"
,
paymentTypeAlipayArray
)
);
);
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
// 开始执行批量提交审核 分批处理退款申请
// 开始执行批量提交审核 分批处理退款申请
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
Id
,
otherParam
);
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
ApplyParam
,
"cancel"
);
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
params
.
setStatus
(
KylinTableStatusConst
.
STATUS_CANCEL
);
params
.
setStatus
(
KylinTableStatusConst
.
STATUS_CANCEL
);
...
@@ -126,8 +131,9 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -126,8 +131,9 @@ public class KylinRefundPerformancesAdminServiceImpl {
}
}
}
}
public
Boolean
refundBatchReview
(
String
refundBatchId
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
public
Boolean
refundBatchReview
(
RefundBatchApplyParam
refundBatchApplyParam
)
throws
Exception
{
Integer
batchStatus
=
(
Integer
)
otherParam
.
get
(
"status"
);
String
refundBatchId
=
refundBatchApplyParam
.
getRefundBatchId
();
Integer
batchStatus
=
refundBatchApplyParam
.
getStatus
();
Integer
updateStatus
=
0
;
Integer
updateStatus
=
0
;
if
(
KylinTableStatusConst
.
STATUS_OPERATE_REJECT
==
batchStatus
)
{
// 驳回
if
(
KylinTableStatusConst
.
STATUS_OPERATE_REJECT
==
batchStatus
)
{
// 驳回
updateStatus
=
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
;
updateStatus
=
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REJECT
;
...
@@ -141,8 +147,8 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -141,8 +147,8 @@ public class KylinRefundPerformancesAdminServiceImpl {
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
// 开始执行批量提交审核 分批处理退款申请
// 开始执行批量提交审核 分批处理退款申请
otherParam
.
put
(
"status"
,
updateStatus
);
refundBatchApplyParam
.
setRefundStatus
(
updateStatus
);
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
Id
,
otherParam
);
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
ApplyParam
,
"review"
);
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
params
.
setStatus
(
batchStatus
);
params
.
setStatus
(
batchStatus
);
...
@@ -154,8 +160,9 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -154,8 +160,9 @@ public class KylinRefundPerformancesAdminServiceImpl {
}
}
}
}
public
Boolean
refundBatchExecute
(
String
refundBatchId
,
HashMap
<
String
,
Object
>
otherParam
)
throws
Exception
{
public
Boolean
refundBatchExecute
(
RefundBatchApplyParam
refundBatchApplyParam
)
throws
Exception
{
Integer
batchStatus
=
(
Integer
)
otherParam
.
get
(
"status"
);
String
refundBatchId
=
refundBatchApplyParam
.
getRefundBatchId
();
Integer
batchStatus
=
refundBatchApplyParam
.
getStatus
();
Integer
updateStatus
=
0
;
Integer
updateStatus
=
0
;
if
(
KylinTableStatusConst
.
STATUS_FINANCE_REJECT
==
batchStatus
)
{
// 驳回
if
(
KylinTableStatusConst
.
STATUS_FINANCE_REJECT
==
batchStatus
)
{
// 驳回
updateStatus
=
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
;
updateStatus
=
KylinTableStatusConst
.
ORDER_REFUND_STATUS_REFUSE
;
...
@@ -169,8 +176,8 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -169,8 +176,8 @@ public class KylinRefundPerformancesAdminServiceImpl {
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
if
(!
refundBatchesInfo
.
getRefundBatchId
().
isEmpty
())
{
// 开始执行批量提交审核 分批处理退款申请
// 开始执行批量提交审核 分批处理退款申请
otherParam
.
put
(
"status"
,
updateStatus
);
refundBatchApplyParam
.
setRefundStatus
(
updateStatus
);
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
Id
,
otherParam
);
kylinRefundExecuteServiceImpl
.
refundBatchStatus
(
refundBatch
ApplyParam
,
"execute"
);
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
KylinOrderRefundBatches
params
=
new
KylinOrderRefundBatches
();
params
.
setStatus
(
batchStatus
);
params
.
setStatus
(
batchStatus
);
...
@@ -194,10 +201,10 @@ public class KylinRefundPerformancesAdminServiceImpl {
...
@@ -194,10 +201,10 @@ public class KylinRefundPerformancesAdminServiceImpl {
return
kylinOrderRefundBatchesVo
;
return
kylinOrderRefundBatchesVo
;
}
}
public
PageInfo
<
OrderRefundBatchDao
>
refundList
(
Integer
page
,
Integer
size
)
{
public
PageInfo
<
OrderRefundBatchDao
>
refundList
(
RefundBatchSearchParam
refundBatchSearchParam
)
{
PageInfo
<
OrderRefundBatchDao
>
pageInfoTmp
=
null
;
PageInfo
<
OrderRefundBatchDao
>
pageInfoTmp
=
null
;
try
{
try
{
PageHelper
.
startPage
(
page
,
size
);
PageHelper
.
startPage
(
refundBatchSearchParam
.
getPageNum
(),
refundBatchSearchParam
.
getPageSize
()
);
List
<
OrderRefundBatchDao
>
voList
=
kylinOrderRefundBatchesMapper
.
misRefundBatchList
();
List
<
OrderRefundBatchDao
>
voList
=
kylinOrderRefundBatchesMapper
.
misRefundBatchList
();
pageInfoTmp
=
new
PageInfo
(
voList
);
pageInfoTmp
=
new
PageInfo
(
voList
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
...
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/entity/KylinOrderRefundBatches.java
View file @
f4cdcbc7
package
com
.
liquidnet
.
service
.
kylin
.
entity
;
package
com
.
liquidnet
.
service
.
kylin
.
entity
;
import
java.math.BigDecimal
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
java.time.LocalDateTime
;
import
java.time.LocalDateTime
;
...
...
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/mapper/KylinOrderTicketsMapper.java
View file @
f4cdcbc7
...
@@ -23,5 +23,5 @@ public interface KylinOrderTicketsMapper extends BaseMapper<KylinOrderTickets> {
...
@@ -23,5 +23,5 @@ public interface KylinOrderTicketsMapper extends BaseMapper<KylinOrderTickets> {
Double
getTotalPrice
(
String
targetId
,
String
selectFields
,
String
[]
paymentType
);
Double
getTotalPrice
(
String
targetId
,
String
selectFields
,
String
[]
paymentType
);
// 获取订单和购票信息
// 获取订单和购票信息
List
getOrder
Entities
(
String
targetId
,
int
mid
,
int
limitNum
);
List
getOrder
List
(
String
targetId
,
int
mid
,
int
limitNum
);
}
}
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/resources/com.liquidnet.service.kylin.mapper/KylinOrderTicketsMapper.xml
View file @
f4cdcbc7
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
</foreach>
</foreach>
</where>
</where>
</select>
</select>
<select
id=
"getOrder
Entities
"
resultType=
"java.util.List"
>
<select
id=
"getOrder
List
"
resultType=
"java.util.List"
>
SELECT o.mid, order_tickets_id, number, price_actual, performance_title
SELECT o.mid, order_tickets_id, number, price_actual, performance_title
FROM kylin_order_tickets AS o
FROM kylin_order_tickets AS o
JOIN kylin_order_ticket_relations AS r ON r.order_id = o.order_tickets_id
JOIN kylin_order_ticket_relations AS r ON r.order_id = o.order_tickets_id
...
...
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