|
|
@ -7,6 +7,7 @@ import com.hai.common.exception.ErrorCode; |
|
|
|
import com.hai.common.exception.ErrorHelp; |
|
|
|
import com.hai.common.exception.ErrorHelp; |
|
|
|
import com.hai.common.exception.SysCode; |
|
|
|
import com.hai.common.exception.SysCode; |
|
|
|
import com.hai.common.security.UserCenter; |
|
|
|
import com.hai.common.security.UserCenter; |
|
|
|
|
|
|
|
import com.hai.common.utils.RedisUtil; |
|
|
|
import com.hai.common.utils.ResponseMsgUtil; |
|
|
|
import com.hai.common.utils.ResponseMsgUtil; |
|
|
|
import com.hai.entity.HighOrder; |
|
|
|
import com.hai.entity.HighOrder; |
|
|
|
import com.hai.entity.OutRechargeChildOrder; |
|
|
|
import com.hai.entity.OutRechargeChildOrder; |
|
|
@ -42,6 +43,7 @@ import javax.annotation.Resource; |
|
|
|
import javax.servlet.http.HttpServletRequest; |
|
|
|
import javax.servlet.http.HttpServletRequest; |
|
|
|
import java.io.File; |
|
|
|
import java.io.File; |
|
|
|
import java.util.*; |
|
|
|
import java.util.*; |
|
|
|
|
|
|
|
import java.util.concurrent.TimeUnit; |
|
|
|
|
|
|
|
|
|
|
|
@Controller |
|
|
|
@Controller |
|
|
|
@RequestMapping(value = "mobileRecharge") |
|
|
|
@RequestMapping(value = "mobileRecharge") |
|
|
@ -65,6 +67,9 @@ public class OrderMobileRechargeController { |
|
|
|
@Autowired |
|
|
|
@Autowired |
|
|
|
private RedisTemplate redisTemplate; |
|
|
|
private RedisTemplate redisTemplate; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
|
|
|
|
private RedisUtil redisUtil; |
|
|
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
@Resource |
|
|
|
private OutRechargeChildOrderService outRechargeChildOrderService; |
|
|
|
private OutRechargeChildOrderService outRechargeChildOrderService; |
|
|
|
|
|
|
|
|
|
|
@ -136,6 +141,7 @@ public class OrderMobileRechargeController { |
|
|
|
@ApiOperation(value = "导出话费订单列表") |
|
|
|
@ApiOperation(value = "导出话费订单列表") |
|
|
|
public ResponseData exportMobilePartyOrderList(@RequestParam(name = "orderNo", required = false) String orderNo, |
|
|
|
public ResponseData exportMobilePartyOrderList(@RequestParam(name = "orderNo", required = false) String orderNo, |
|
|
|
@RequestParam(name = "memPhone", required = false) String memPhone, |
|
|
|
@RequestParam(name = "memPhone", required = false) String memPhone, |
|
|
|
|
|
|
|
@RequestParam(name = "serialNumber", required = false) String serialNumber, |
|
|
|
@RequestParam(name = "memCardNo", required = false) String memCardNo, |
|
|
|
@RequestParam(name = "memCardNo", required = false) String memCardNo, |
|
|
|
@RequestParam(name = "payType", required = false) Integer payType, |
|
|
|
@RequestParam(name = "payType", required = false) Integer payType, |
|
|
|
@RequestParam(name = "orderStatus", required = false) Integer orderStatus, |
|
|
|
@RequestParam(name = "orderStatus", required = false) Integer orderStatus, |
|
|
@ -150,6 +156,7 @@ public class OrderMobileRechargeController { |
|
|
|
@RequestParam(name = "refundTimeS", required = false) Long refundTimeS, |
|
|
|
@RequestParam(name = "refundTimeS", required = false) Long refundTimeS, |
|
|
|
@RequestParam(name = "refundTimeE", required = false) Long refundTimeE, |
|
|
|
@RequestParam(name = "refundTimeE", required = false) Long refundTimeE, |
|
|
|
@RequestParam(name = "finishTimeS", required = false) Long finishTimeS, |
|
|
|
@RequestParam(name = "finishTimeS", required = false) Long finishTimeS, |
|
|
|
|
|
|
|
|
|
|
|
@RequestParam(name = "finishTimeE", required = false) Long finishTimeE) { |
|
|
|
@RequestParam(name = "finishTimeE", required = false) Long finishTimeE) { |
|
|
|
try { |
|
|
|
try { |
|
|
|
|
|
|
|
|
|
|
@ -187,8 +194,20 @@ public class OrderMobileRechargeController { |
|
|
|
|
|
|
|
|
|
|
|
List<ExportOrderMobileModel> list = new ArrayList<>(); |
|
|
|
List<ExportOrderMobileModel> list = new ArrayList<>(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 配置初始化处理条数
|
|
|
|
|
|
|
|
int i = 0; |
|
|
|
|
|
|
|
int percent; |
|
|
|
|
|
|
|
|
|
|
|
ExportOrderMobileModel model; |
|
|
|
ExportOrderMobileModel model; |
|
|
|
for (HighOrder highOrder : order) { |
|
|
|
for (HighOrder highOrder : order) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
i++; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 生成百分比
|
|
|
|
|
|
|
|
percent = i*100/order.size(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
redisUtil.set(serialNumber , percent , 3600); |
|
|
|
|
|
|
|
|
|
|
|
model = new ExportOrderMobileModel(); |
|
|
|
model = new ExportOrderMobileModel(); |
|
|
|
|
|
|
|
|
|
|
|
OutRechargeOrder rechargeOrder = outRechargeOrderService.findByOrderNoNotChild(highOrder.getOrderNo()); |
|
|
|
OutRechargeOrder rechargeOrder = outRechargeOrderService.findByOrderNoNotChild(highOrder.getOrderNo()); |
|
|
@ -235,6 +254,8 @@ public class OrderMobileRechargeController { |
|
|
|
.head(ExportOrderMobileModel.class) |
|
|
|
.head(ExportOrderMobileModel.class) |
|
|
|
.sheet("话费交易订单") |
|
|
|
.sheet("话费交易订单") |
|
|
|
.doWrite(list); |
|
|
|
.doWrite(list); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
redisUtil.set(serialNumber + "download" , pathName , 600); |
|
|
|
return ResponseMsgUtil.success(pathName); |
|
|
|
return ResponseMsgUtil.success(pathName); |
|
|
|
|
|
|
|
|
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
|