ソースを参照

添加代理商账户导出 开户时间

syh 5 年 前
コミット
d5bd147dda

+ 34 - 33
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/KuaishouAgentAccountController.java

@@ -1,40 +1,40 @@
 package org.jeecg.modules.ctop.controller;
 
-import java.io.OutputStream;
-import java.util.*;
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.URLDecoder;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
 import cn.com.ctop.common.module.utils.ExportExcelUtils;
-import org.apache.poi.xssf.usermodel.XSSFWorkbook;
-import org.jeecg.common.api.vo.Result;
-import org.jeecg.common.system.query.QueryGenerator;
-import org.jeecg.common.aspect.annotation.AutoLog;
-import org.jeecg.common.util.oConvertUtils;
 import cn.com.ctop.kuaishou.modules.report.entity.KuaishouAgentAccount;
 import cn.com.ctop.kuaishou.modules.report.service.IKuaishouAgentAccountService;
+import com.alibaba.fastjson.JSON;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
 import lombok.extern.slf4j.Slf4j;
-
+import org.apache.poi.xssf.usermodel.XSSFWorkbook;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.util.DateUtils;
+import org.jeecg.common.util.oConvertUtils;
 import org.jeecgframework.poi.excel.ExcelImportUtil;
-import org.jeecgframework.poi.excel.def.NormalExcelConstants;
-import org.jeecgframework.poi.excel.entity.ExportParams;
 import org.jeecgframework.poi.excel.entity.ImportParams;
 import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
-
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.multipart.MultipartFile;
 import org.springframework.web.multipart.MultipartHttpServletRequest;
 import org.springframework.web.servlet.ModelAndView;
-import com.alibaba.fastjson.JSON;
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+import java.io.OutputStream;
+import java.io.UnsupportedEncodingException;
+import java.net.URLDecoder;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
 
  /**
  * 快手代理商账户表
@@ -49,7 +49,7 @@ import io.swagger.annotations.ApiOperation;
 public class KuaishouAgentAccountController {
 	@Autowired
 	private IKuaishouAgentAccountService kuaishouAgentAccountService;
-	
+
 	/**
 	  * 分页列表查询
 	 * @param kuaishouAgentAccount
@@ -73,7 +73,7 @@ public class KuaishouAgentAccountController {
 		result.setResult(pageList);
 		return result;
 	}
-	
+
 	/**
 	  *   添加
 	 * @param kuaishouAgentAccount
@@ -93,8 +93,8 @@ public class KuaishouAgentAccountController {
 		}
 		return result;
 	}
-	
-	/**
+
+     /**
 	  *  编辑
 	 * @param kuaishouAgentAccount
 	 * @return
@@ -113,11 +113,11 @@ public class KuaishouAgentAccountController {
 				result.success("修改成功!");
 			}
 		}
-		
-		return result;
+
+        return result;
 	}
-	
-	/**
+
+     /**
 	  *   通过id删除
 	 * @param id
 	 * @return
@@ -134,8 +134,8 @@ public class KuaishouAgentAccountController {
 		}
 		return Result.ok("删除成功!");
 	}
-	
-	/**
+
+     /**
 	  *  批量删除
 	 * @param ids
 	 * @return
@@ -153,8 +153,8 @@ public class KuaishouAgentAccountController {
 		}
 		return result;
 	}
-	
-	/**
+
+     /**
 	  * 通过id查询
 	 * @param id
 	 * @return
@@ -212,6 +212,7 @@ public class KuaishouAgentAccountController {
 			rowData.add(kuaishouAgentAccount.getDirectRebate());
 			rowData.add(kuaishouAgentAccount.getTotalBalance());
 			rowData.add(kuaishouAgentAccount.getCorporationName());
+            rowData.add(DateUtils.formatDate(kuaishouAgentAccount.getCreateTime()));
 			if(kuaishouAgentAccount.getReviewStatus() == 1){
 				rowData.add("审核中");
 			}else if(kuaishouAgentAccount.getReviewStatus() == 2){
@@ -222,7 +223,7 @@ public class KuaishouAgentAccountController {
 			result.add(rowData);
 		}
 	  }
-	  String[] accountHeaders = {"广告主ID", "用户ID", "广告主名称", "现金余额", "信用余额", "返点余额", "框返余额", "激励余额", "总余额", "公司名称", "审核状态"};
+      String[] accountHeaders = {"广告主ID", "用户ID", "广告主名称", "现金余额", "信用余额", "返点余额", "框返余额", "激励余额", "总余额", "公司名称", "开户时间", "审核状态"};
 	  OutputStream os = response.getOutputStream();
 	  ExportExcelUtils eeu = new ExportExcelUtils();
 	  XSSFWorkbook workbook = new XSSFWorkbook();

+ 5 - 7
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/entity/KuaishouAgentAccount.java

@@ -1,21 +1,18 @@
 package cn.com.ctop.kuaishou.modules.report.entity;
 
-import java.io.Serializable;
-import java.util.Date;
 import com.baomidou.mybatisplus.annotation.IdType;
 import com.baomidou.mybatisplus.annotation.TableId;
 import com.baomidou.mybatisplus.annotation.TableName;
-import com.baomidou.mybatisplus.annotation.TableField;
 import com.fasterxml.jackson.annotation.JsonProperty;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
 import lombok.experimental.Accessors;
-import com.fasterxml.jackson.annotation.JsonFormat;
-import org.springframework.format.annotation.DateTimeFormat;
 import org.jeecgframework.poi.excel.annotation.Excel;
 
+import java.util.Date;
+
 /**
  * 快手代理商账户表
  * @author jeecg-boot
@@ -28,7 +25,7 @@ import org.jeecgframework.poi.excel.annotation.Excel;
 @Accessors(chain = true)
 @ApiModel(value="ctop_kuaishou_agent_account对象", description="快手代理商账户表")
 public class KuaishouAgentAccount {
-    
+
 	/**id*/
 	@TableId(type = IdType.INPUT)
     @ApiModelProperty(value = "id")
@@ -103,6 +100,7 @@ public class KuaishouAgentAccount {
     @ApiModelProperty(value = "transferAccountStatus")
 	private Boolean transferAccountStatus;
 	/**createTime*/
+    @Excel(name = "transferAccountStatus", width = 15)
     @ApiModelProperty(value = "createTime")
-	private Date createTime;
+    private Date createTime;
 }