|
@@ -3,6 +3,7 @@ package com.yonge.cooleshow.admin.controller;
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
|
|
|
import com.yonge.cooleshow.biz.dal.dto.excel.UserOrderExport;
|
|
|
+import com.yonge.cooleshow.biz.dal.dto.excel.UserWithdrawalExport;
|
|
|
import com.yonge.cooleshow.biz.dal.dto.search.OrderSearch;
|
|
|
import com.yonge.cooleshow.biz.dal.support.PageUtil;
|
|
|
import com.yonge.cooleshow.biz.dal.vo.UserOrderVo;
|
|
@@ -13,6 +14,7 @@ import com.yonge.toolset.utils.easyexcel.ExcelUtils;
|
|
|
import io.swagger.annotations.*;
|
|
|
import org.apache.commons.beanutils.BeanUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.util.DigestUtils;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import com.yonge.cooleshow.biz.dal.vo.UserWithdrawalVo;
|
|
@@ -53,19 +55,20 @@ public class UserWithdrawalController extends BaseController {
|
|
|
/**
|
|
|
* 查询导出
|
|
|
*/
|
|
|
- @GetMapping("/export")
|
|
|
+ @PostMapping("/export")
|
|
|
@ApiOperation(value = "查询导出", notes = "传入TeacherWithdrawalSearch")
|
|
|
- public void export(TeacherWithdrawalSearch query) {
|
|
|
+ public void export(@RequestBody TeacherWithdrawalSearch query) {
|
|
|
List<UserWithdrawalVo> withdrawalVoList = userWithdrawalService.selectList(query);
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- List<UserOrderExport> list = new ArrayList<>();
|
|
|
+ List<UserWithdrawalExport> list = new ArrayList<>();
|
|
|
withdrawalVoList.forEach(o-> {
|
|
|
- UserOrderExport export = new UserOrderExport();
|
|
|
+ UserWithdrawalExport export = new UserWithdrawalExport();
|
|
|
try {
|
|
|
BeanUtils.copyProperties(export,o);
|
|
|
+ StringBuffer buffer = new StringBuffer(export.getId().toString());
|
|
|
+ buffer.append(export.getAmount());
|
|
|
+ buffer.append(export.getActualAmount());
|
|
|
+ String s = DigestUtils.md5DigestAsHex(buffer.toString().getBytes());
|
|
|
+ export.setSign(s);
|
|
|
list.add(export);
|
|
|
} catch (IllegalAccessException e) {
|
|
|
e.printStackTrace();
|
|
@@ -73,8 +76,8 @@ public class UserWithdrawalController extends BaseController {
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
});
|
|
|
- ExcelUtils.exportExcel(list, "订单列表数据" + System.currentTimeMillis(),
|
|
|
- "订单列表数据");
|
|
|
+ ExcelUtils.exportExcel(list, "提现列表数据" + System.currentTimeMillis(),
|
|
|
+ "列表数据");
|
|
|
}
|
|
|
|
|
|
|