记得上下班打卡 | git大法好,push需谨慎

Commit f83e68a8 authored by jiangxiulong's avatar jiangxiulong

admin 批量退款数量20改成1000减少http连接数;防止多次操作财务审核处理增加判断,运营审核或者票务审核通过才能处理

parent 87d1aeb0
...@@ -137,7 +137,7 @@ public class KylinRefundExecuteServiceImpl { ...@@ -137,7 +137,7 @@ public class KylinRefundExecuteServiceImpl {
} }
int count = 0; int count = 0;
int limitNum = 20; int limitNum = 1000;
int mid = 0; int mid = 0;
do { do {
List<KylinOrderRefunds> refundList = kylinOrderRefundsMapper.getRefundList(whereType, refundBatchId, whereStatus, mid, limitNum); List<KylinOrderRefunds> refundList = kylinOrderRefundsMapper.getRefundList(whereType, refundBatchId, whereStatus, mid, limitNum);
......
...@@ -3,6 +3,7 @@ package com.liquidnet.client.admin.zhengzai.kylin.service.impl; ...@@ -3,6 +3,7 @@ package com.liquidnet.client.admin.zhengzai.kylin.service.impl;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.liquidnet.client.admin.common.utils.StringUtils; import com.liquidnet.client.admin.common.utils.StringUtils;
import com.liquidnet.client.admin.zhengzai.kylin.utils.DataUtils; import com.liquidnet.client.admin.zhengzai.kylin.utils.DataUtils;
import com.liquidnet.client.admin.zhengzai.kylin.utils.MongoVoUtils; import com.liquidnet.client.admin.zhengzai.kylin.utils.MongoVoUtils;
...@@ -41,6 +42,7 @@ import java.time.LocalDateTime; ...@@ -41,6 +42,7 @@ import java.time.LocalDateTime;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Objects;
import java.util.stream.Collectors; import java.util.stream.Collectors;
/** /**
...@@ -403,6 +405,15 @@ public class KylinRefundsStatusServiceImpl { ...@@ -403,6 +405,15 @@ public class KylinRefundsStatusServiceImpl {
kylinOrderRefunds.setRefuse(refundApplyParam.getRefuse()); kylinOrderRefunds.setRefuse(refundApplyParam.getRefuse());
for (KylinOrderRefunds refund : refundList) { for (KylinOrderRefunds refund : refundList) {
KylinOrderRefunds orderRefundsOld = kylinOrderRefundsMapper.selectOne(
Wrappers.lambdaQuery(KylinOrderRefunds.class)
.eq(KylinOrderRefunds::getOrderRefundsId, refund.getOrderRefundsId())
);
if (!Objects.equals(orderRefundsOld.getStatus(), KylinTableStatusConst.ORDER_REFUND_STATUS_APPROVED)
&& !Objects.equals(orderRefundsOld.getStatus(), KylinTableStatusConst.ORDER_REFUND_STATUS_TICKET)
) {
continue;
}
// 更新退款表 // 更新退款表
kylinOrderRefunds.setUpdatedAt(LocalDateTime.now()); kylinOrderRefunds.setUpdatedAt(LocalDateTime.now());
kylinOrderRefundsMapper.update( kylinOrderRefundsMapper.update(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment