| | |
| | | import cc.mrbird.febs.mall.service.IAdminMallMemberService; |
| | | import cc.mrbird.febs.mall.service.IApiMallMemberService; |
| | | import cc.mrbird.febs.mall.vo.AdminAgentLevelOptionTreeVo; |
| | | import cc.mrbird.febs.mall.vo.ChargeListExportVo; |
| | | import cc.mrbird.febs.system.entity.Dept; |
| | | import com.alibaba.excel.EasyExcel; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.ibatis.annotations.Param; |
| | |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import javax.validation.Valid; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.io.IOException; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLEncoder; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | |
| | | return null; |
| | | } |
| | | |
| | | @GetMapping(value = "/chargeList/excel") |
| | | public void exportChargeList(MoneyChargeListDto moneyChargeListDto, HttpServletResponse response) throws IOException { |
| | | List<ChargeListExportVo> list = this.mallMemberService.findChargeListForExcel(moneyChargeListDto); |
| | | |
| | | response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); |
| | | response.setCharacterEncoding("utf-8"); |
| | | String fileName= URLEncoder.encode("提现列表","UTF-8").replaceAll("\\+","%20"); |
| | | response.setHeader("Content-disposition","attachment;filename*=utf-8''"+fileName+".xlsx"); |
| | | EasyExcel.write(response.getOutputStream(),ChargeListExportVo.class).sheet("提现列表").doWrite(list); |
| | | } |
| | | |
| | | } |