feat: 各模块支持自定义导出
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
package org.agt.module.license.controller.admin.common.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @description: 通用导出字段参数
|
||||
* @author: cyc
|
||||
* @since: 2025-09-12
|
||||
*/
|
||||
@Schema(description = "管理后台 - 通用导出字段参数 Request VO")
|
||||
@Data
|
||||
public class CommonExportFieldsReqVO {
|
||||
|
||||
@Schema(description = "字段")
|
||||
private String field;
|
||||
|
||||
@Schema(description = "标题")
|
||||
private String title;
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
package org.agt.module.license.controller.admin.common.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* @description: 通用导出参数
|
||||
* @author: cyc
|
||||
* @since: 2025-09-12
|
||||
*/
|
||||
|
||||
@Schema(description = "管理后台 - 通用导出参数 Request VO")
|
||||
@Data
|
||||
public class CommonExportReqVO extends PageParam {
|
||||
|
||||
@Schema(description = "文件名")
|
||||
private String filename;
|
||||
|
||||
@Schema(description = "sheet名称")
|
||||
private String sheetName;
|
||||
|
||||
@Schema(description = "是否表头")
|
||||
private Boolean isHeader;
|
||||
|
||||
@Schema(description = "是否源数据")
|
||||
private Boolean original;
|
||||
|
||||
@Schema(description = "选择数据")
|
||||
private String mode;
|
||||
|
||||
@Schema(description = "ids")
|
||||
private List<String> ids;
|
||||
|
||||
@Schema(description = "选择字段")
|
||||
private List<CommonExportFieldsReqVO> fields;
|
||||
|
||||
@Schema(description = "已选择字段")
|
||||
private Set<String> includeFields;
|
||||
}
|
||||
@@ -166,11 +166,13 @@ public class CustomerController {
|
||||
@ApiAccessLog(operateType = EXPORT)
|
||||
public void exportCustomerExcel(@Valid CustomerPageReqVO pageReqVO,
|
||||
HttpServletResponse response) throws IOException {
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
if ("all".equals(pageReqVO.getMode())) {
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
}
|
||||
PageResult<CustomerDO> pageResult = customerService.getCustomerPage(pageReqVO);
|
||||
// 导出 Excel
|
||||
ExcelUtils.write(response, "客户.xlsx", "数据", CustomerRespVO.class,
|
||||
buildCustomerVOList(pageResult).getList());
|
||||
ExcelUtils.writeSelected(response, "", pageReqVO.getSheetName(), CustomerRespVO.class,
|
||||
buildCustomerVOList(pageResult).getList(), pageReqVO.getIncludeFields());
|
||||
}
|
||||
|
||||
private static PageResult<CustomerRespVO> buildCustomerVOList(PageResult<CustomerDO> pageResult) {
|
||||
|
||||
@@ -4,7 +4,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.ToString;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.module.license.controller.admin.common.vo.CommonExportReqVO;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
@@ -15,7 +15,7 @@ import static org.agt.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class CustomerPageReqVO extends PageParam {
|
||||
public class CustomerPageReqVO extends CommonExportReqVO {
|
||||
|
||||
@Schema(description = "客户名称", example = "赵六")
|
||||
private String name;
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package org.agt.module.license.controller.admin.license;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
@@ -13,8 +11,6 @@ import org.agt.framework.apilog.core.annotation.ApiAccessLog;
|
||||
import org.agt.framework.common.pojo.CommonResult;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.framework.common.pojo.PageResult;
|
||||
import org.agt.framework.common.util.object.BeanUtils;
|
||||
import org.agt.framework.dict.core.DictFrameworkUtils;
|
||||
import org.agt.framework.excel.core.util.ExcelUtils;
|
||||
import org.agt.framework.translate.core.TranslateUtils;
|
||||
import org.agt.module.license.controller.admin.license.vo.ImportRespVO;
|
||||
@@ -39,7 +35,6 @@ import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.time.LocalDate;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
@@ -142,49 +137,51 @@ public class LicenseController {
|
||||
@ApiAccessLog(operateType = EXPORT)
|
||||
public void exportLicenseExcel(@Valid LicensePageReqVO pageReqVO,
|
||||
HttpServletResponse response) throws IOException {
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
if ("all".equals(pageReqVO.getMode())) {
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
}
|
||||
List<LicenseRespVO> voList = licenseService.getLicensePage(pageReqVO).getList();
|
||||
|
||||
List<LicenseRespVO> results = new ArrayList<>();
|
||||
for (LicenseRespVO license : voList) {
|
||||
license.setExpiryDateExt(license.getExpiryDate().toLocalDate());
|
||||
List<LicenseDetailVO> neCodeList = license.getNeCodeList();
|
||||
if (CollUtil.isEmpty(neCodeList)) {
|
||||
results.add(license);
|
||||
} else {
|
||||
for (LicenseDetailVO licenseDetailVO : neCodeList) {
|
||||
LicenseRespVO licenseVO = new LicenseRespVO();
|
||||
BeanUtils.copyProperties(license, licenseVO);
|
||||
|
||||
List<String> neLabels = new ArrayList<>();
|
||||
for (Integer ne : licenseDetailVO.getNeList()) {
|
||||
String label = DictFrameworkUtils.parseDictDataLabel("lic_ne_all", ne.toString());
|
||||
if (StrUtil.isBlank(label)) {
|
||||
label = DictFrameworkUtils.parseDictDataLabel("lic_ne_5g", ne.toString());
|
||||
if (StrUtil.isBlank(label)) {
|
||||
label = DictFrameworkUtils.parseDictDataLabel("lic_ne_4g", ne.toString());
|
||||
if (StrUtil.isBlank(label)) {
|
||||
label = DictFrameworkUtils.parseDictDataLabel("lic_ne_23g", ne.toString());
|
||||
if (StrUtil.isBlank(label)) {
|
||||
label = DictFrameworkUtils.parseDictDataLabel("lic_ne_add", ne.toString());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
neLabels.add(label);
|
||||
}
|
||||
String neListStr = StrUtil.join("_", neLabels);
|
||||
|
||||
licenseVO.setNeListStr(neListStr);
|
||||
licenseVO.setActivationCode(licenseDetailVO.getActivationCode());
|
||||
results.add(licenseVO);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
// List<LicenseRespVO> results = new ArrayList<>();
|
||||
// for (LicenseRespVO license : voList) {
|
||||
// license.setExpiryDateExt(license.getExpiryDate().toLocalDate());
|
||||
// List<LicenseDetailVO> neCodeList = license.getNeCodeList();
|
||||
// if (CollUtil.isEmpty(neCodeList)) {
|
||||
// results.add(license);
|
||||
// } else {
|
||||
// for (LicenseDetailVO licenseDetailVO : neCodeList) {
|
||||
// LicenseRespVO licenseVO = new LicenseRespVO();
|
||||
// BeanUtils.copyProperties(license, licenseVO);
|
||||
//
|
||||
// List<String> neLabels = new ArrayList<>();
|
||||
// for (Integer ne : licenseDetailVO.getNeList()) {
|
||||
// String label = DictFrameworkUtils.parseDictDataLabel("lic_ne_all", ne.toString());
|
||||
// if (StrUtil.isBlank(label)) {
|
||||
// label = DictFrameworkUtils.parseDictDataLabel("lic_ne_5g", ne.toString());
|
||||
// if (StrUtil.isBlank(label)) {
|
||||
// label = DictFrameworkUtils.parseDictDataLabel("lic_ne_4g", ne.toString());
|
||||
// if (StrUtil.isBlank(label)) {
|
||||
// label = DictFrameworkUtils.parseDictDataLabel("lic_ne_23g", ne.toString());
|
||||
// if (StrUtil.isBlank(label)) {
|
||||
// label = DictFrameworkUtils.parseDictDataLabel("lic_ne_add", ne.toString());
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// neLabels.add(label);
|
||||
// }
|
||||
// String neListStr = StrUtil.join("_", neLabels);
|
||||
//
|
||||
// licenseVO.setNeListStr(neListStr);
|
||||
// licenseVO.setActivationCode(licenseDetailVO.getActivationCode());
|
||||
// results.add(licenseVO);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// }
|
||||
// 导出 Excel
|
||||
ExcelUtils.write(response, "License.xlsx", "数据", LicenseRespVO.class,
|
||||
TranslateUtils.translate(results));
|
||||
ExcelUtils.writeSelected(response, "", pageReqVO.getSheetName(), LicenseRespVO.class,
|
||||
TranslateUtils.translate(voList), pageReqVO.getIncludeFields());
|
||||
}
|
||||
|
||||
@GetMapping("/sn-unique")
|
||||
|
||||
@@ -4,7 +4,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.ToString;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.module.license.controller.admin.common.vo.CommonExportReqVO;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
@@ -16,7 +16,7 @@ import static org.agt.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class LicensePageReqVO extends PageParam {
|
||||
public class LicensePageReqVO extends CommonExportReqVO {
|
||||
|
||||
@Schema(description = "客户ID", example = "31667")
|
||||
private Long customerId;
|
||||
|
||||
@@ -106,11 +106,13 @@ public class ProjectController {
|
||||
@ApiAccessLog(operateType = EXPORT)
|
||||
public void exportProjectExcel(@Valid ProjectPageReqVO pageReqVO,
|
||||
HttpServletResponse response) throws IOException {
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
if ("all".equals(pageReqVO.getMode())) {
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
}
|
||||
List<ProjectRespVO> list = projectService.getProjectPage(pageReqVO).getList();
|
||||
// 导出 Excel
|
||||
ExcelUtils.write(response, "项目.xlsx", "项目列表", ProjectRespVO.class,
|
||||
TranslateUtils.translate(list));
|
||||
ExcelUtils.writeSelected(response, "项目.xlsx", pageReqVO.getSheetName(), ProjectRespVO.class,
|
||||
TranslateUtils.translate(list), pageReqVO.getIncludeFields());
|
||||
}
|
||||
|
||||
@GetMapping("/name-unique")
|
||||
|
||||
@@ -76,4 +76,10 @@ public class ProjectListReqVO extends PageParam {
|
||||
|
||||
@Schema(description = "技术负责人")
|
||||
private Long technicalOwner;
|
||||
|
||||
@Schema(description = "排列字段")
|
||||
private String sortField;
|
||||
|
||||
@Schema(description = "排列顺序")
|
||||
private String sortOrder;
|
||||
}
|
||||
@@ -4,7 +4,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.ToString;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.module.license.controller.admin.common.vo.CommonExportReqVO;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
@@ -15,7 +15,7 @@ import static org.agt.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class ProjectPageReqVO extends PageParam {
|
||||
public class ProjectPageReqVO extends CommonExportReqVO {
|
||||
|
||||
@Schema(description = "项目名称", example = "aa")
|
||||
private String name;
|
||||
|
||||
@@ -3,19 +3,29 @@ package org.agt.module.license.controller.admin.report;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import jakarta.annotation.Resource;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.Valid;
|
||||
import org.agt.framework.apilog.core.annotation.ApiAccessLog;
|
||||
import org.agt.framework.common.pojo.CommonResult;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.framework.common.pojo.PageResult;
|
||||
import org.agt.framework.common.util.object.BeanUtils;
|
||||
import org.agt.framework.excel.core.util.ExcelUtils;
|
||||
import org.agt.module.license.controller.admin.common.vo.CommonExportReqVO;
|
||||
import org.agt.module.license.controller.admin.report.vo.ReportLicensePageReqVO;
|
||||
import org.agt.module.license.controller.admin.report.vo.ReportLicenseRespVO;
|
||||
import org.agt.module.license.controller.admin.report.vo.ReportProgressProjectReqVO;
|
||||
import org.agt.module.license.controller.admin.report.vo.ReportProgressProjectRespVO;
|
||||
import org.agt.module.license.service.report.ReportService;
|
||||
import org.jsoup.Jsoup;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
import static org.agt.framework.apilog.core.enums.OperateTypeEnum.EXPORT;
|
||||
import static org.agt.framework.common.pojo.CommonResult.success;
|
||||
|
||||
@Tag(name = "管理后台 - 报表")
|
||||
@@ -47,4 +57,63 @@ public class ReportController {
|
||||
PageResult<ReportLicenseRespVO> pageResult = reportService.getExpiryLicense(query);
|
||||
return success(pageResult);
|
||||
}
|
||||
|
||||
@GetMapping("/project/export-excel")
|
||||
@Operation(summary = "导出项目维度的评论列表 Excel")
|
||||
@ApiAccessLog(operateType = EXPORT)
|
||||
public void exportProjectExcel(@Valid ReportProgressProjectReqVO pageReqVO,
|
||||
HttpServletResponse response) throws IOException {
|
||||
if ("all".equals(pageReqVO.getMode())) {
|
||||
CommonExportReqVO exportReqVO = BeanUtils.toBean(pageReqVO, CommonExportReqVO.class);
|
||||
pageReqVO = BeanUtils.toBean(exportReqVO, ReportProgressProjectReqVO.class);
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
}
|
||||
PageResult<ReportProgressProjectRespVO> pageResult = reportService.getCommentByProject(pageReqVO);
|
||||
|
||||
for (ReportProgressProjectRespVO record : pageResult.getList()) {
|
||||
record.setContent(Jsoup.parse(record.getContent()).wholeText());
|
||||
}
|
||||
|
||||
// 导出 Excel
|
||||
ExcelUtils.writeSelected(response, "", pageReqVO.getSheetName(), ReportProgressProjectRespVO.class,
|
||||
pageResult.getList(), pageReqVO.getIncludeFields());
|
||||
}
|
||||
|
||||
@GetMapping("/staff/export-excel")
|
||||
@Operation(summary = "导出人员维度的评论列表 Excel")
|
||||
@ApiAccessLog(operateType = EXPORT)
|
||||
public void exportStaffExcel(@Valid ReportProgressProjectReqVO pageReqVO,
|
||||
HttpServletResponse response) throws IOException {
|
||||
if ("all".equals(pageReqVO.getMode())) {
|
||||
CommonExportReqVO exportReqVO = BeanUtils.toBean(pageReqVO, CommonExportReqVO.class);
|
||||
pageReqVO = BeanUtils.toBean(exportReqVO, ReportProgressProjectReqVO.class);
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
}
|
||||
PageResult<ReportProgressProjectRespVO> pageResult = reportService.getCommentByStaff(pageReqVO);
|
||||
|
||||
for (ReportProgressProjectRespVO record : pageResult.getList()) {
|
||||
record.setContent(Jsoup.parse(record.getContent()).wholeText());
|
||||
}
|
||||
|
||||
// 导出 Excel
|
||||
ExcelUtils.writeSelected(response, "", pageReqVO.getSheetName(), ReportProgressProjectRespVO.class,
|
||||
pageResult.getList(), pageReqVO.getIncludeFields());
|
||||
}
|
||||
|
||||
@GetMapping("/expire/export-excel")
|
||||
@Operation(summary = "导出到期的License列表 Excel")
|
||||
@ApiAccessLog(operateType = EXPORT)
|
||||
public void exportExpireExcel(@Valid ReportLicensePageReqVO pageReqVO,
|
||||
HttpServletResponse response) throws IOException {
|
||||
if ("all".equals(pageReqVO.getMode())) {
|
||||
CommonExportReqVO exportReqVO = BeanUtils.toBean(pageReqVO, CommonExportReqVO.class);
|
||||
pageReqVO = BeanUtils.toBean(exportReqVO, ReportLicensePageReqVO.class);
|
||||
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||
}
|
||||
PageResult<ReportLicenseRespVO> pageResult = reportService.getExpiryLicense(pageReqVO);
|
||||
// 导出 Excel
|
||||
ExcelUtils.writeSelected(response, "", pageReqVO.getSheetName(), ReportLicenseRespVO.class,
|
||||
pageResult.getList(), pageReqVO.getIncludeFields());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -4,7 +4,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.ToString;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.module.license.controller.admin.common.vo.CommonExportReqVO;
|
||||
import org.agt.module.license.controller.admin.license.vo.LicenseDetailVO;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
@@ -19,7 +19,7 @@ import static org.agt.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class ReportLicensePageReqVO extends PageParam {
|
||||
public class ReportLicensePageReqVO extends CommonExportReqVO {
|
||||
|
||||
@Schema(description = "客户ID", example = "31667")
|
||||
private Long customerId;
|
||||
|
||||
@@ -36,37 +36,37 @@ public class ReportLicenseRespVO implements VO {
|
||||
@ExcelProperty("项目名称")
|
||||
private String projectName;
|
||||
|
||||
|
||||
@Schema(description = "项目状态", example = "18334")
|
||||
@ExcelProperty(value = "项目状态", converter = DictConvert.class)
|
||||
@DictFormat("lic_project_status")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description = "商务状态", example = "18334")
|
||||
@ExcelProperty(value = "商务状态", converter = DictConvert.class)
|
||||
@DictFormat("lic_business_status")
|
||||
private Integer businessStatus;
|
||||
|
||||
@Schema(description = "sn", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("SN")
|
||||
private String serialNo;
|
||||
|
||||
@Schema(description = "到期时间")
|
||||
private LocalDateTime expiryDate;
|
||||
|
||||
@Schema(description = "到期时间格式化")
|
||||
private LocalDateTime expiryDateFormat;
|
||||
|
||||
@Schema(description = "到期时间导出")
|
||||
@ExcelProperty("到期时间")
|
||||
private LocalDate expiryDateExt;
|
||||
|
||||
@Schema(description = "网元")
|
||||
@ExcelProperty("网元")
|
||||
private String neListStr;
|
||||
|
||||
@Schema(description = "激活码")
|
||||
@ExcelProperty("激活码")
|
||||
private String activationCode;
|
||||
|
||||
@Schema(description = "网元激活码列表")
|
||||
private List<LicenseDetailVO> neCodeList;
|
||||
|
||||
@Schema(description = "用户数")
|
||||
@ExcelProperty("用户数")
|
||||
private Integer userNumber;
|
||||
|
||||
@Schema(description = "基站数")
|
||||
@ExcelProperty("基站数")
|
||||
private Integer ranNumber;
|
||||
|
||||
@Schema(description = "文件URL")
|
||||
@@ -77,50 +77,48 @@ public class ReportLicenseRespVO implements VO {
|
||||
private Long applicant;
|
||||
|
||||
@Schema(description = "申请人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("申请人")
|
||||
private String applicantName;
|
||||
|
||||
@Schema(description = "审批人")
|
||||
private Long approver;
|
||||
|
||||
@Schema(description = "审批人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("审批人")
|
||||
private String approverName;
|
||||
|
||||
@Schema(description = "状态", example = "1")
|
||||
@ExcelProperty(value = "状态", converter = DictConvert.class)
|
||||
@DictFormat("lic_license_status") // TODO 代码优化:建议设置到对应的 DictTypeConstants 枚举类中
|
||||
private Integer status;
|
||||
|
||||
@Schema(description = "商务状态", example = "1")
|
||||
private Integer businessStatus;
|
||||
|
||||
@Schema(description = "备注", example = "随便")
|
||||
@ExcelProperty("说明")
|
||||
private String remark;
|
||||
|
||||
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
// @ExcelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Schema(description = "申请时间")
|
||||
@ExcelProperty("申请时间")
|
||||
private LocalDateTime applicationTime;
|
||||
|
||||
@Schema(description = "license申请次数")
|
||||
@ExcelProperty("申请次数")
|
||||
private Integer applyCount;
|
||||
|
||||
@Schema(description = "业务负责人")
|
||||
@ExcelProperty("业务负责人")
|
||||
private String businessOwnerName;
|
||||
|
||||
@Schema(description = "技术负责人1")
|
||||
@ExcelProperty("技术负责人1")
|
||||
private String technicalOwnerAName;
|
||||
|
||||
@Schema(description = "技术负责人2")
|
||||
@ExcelProperty("技术负责人2")
|
||||
private String technicalOwnerBName;
|
||||
|
||||
@Schema(description = "项目开始时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("项目开始时间")
|
||||
private LocalDateTime startTime;
|
||||
|
||||
@Schema(description = "到期时间导出")
|
||||
private LocalDate expiryDateExt;
|
||||
|
||||
@Schema(description = "到期时间")
|
||||
@ExcelProperty("到期时间")
|
||||
private LocalDateTime expiryDate;
|
||||
|
||||
@Schema(description = "申请时间")
|
||||
@ExcelProperty("申请时间")
|
||||
private LocalDateTime applicationTime;
|
||||
|
||||
@Schema(description = "license申请次数")
|
||||
private Integer applyCount;
|
||||
}
|
||||
@@ -4,7 +4,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.ToString;
|
||||
import org.agt.framework.common.pojo.PageParam;
|
||||
import org.agt.module.license.controller.admin.common.vo.CommonExportReqVO;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.time.LocalDate;
|
||||
@@ -17,7 +17,7 @@ import static org.agt.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class ReportProgressProjectReqVO extends PageParam {
|
||||
public class ReportProgressProjectReqVO extends CommonExportReqVO {
|
||||
|
||||
@Schema(description = "主键", requiredMode = Schema.RequiredMode.REQUIRED, example = "4294")
|
||||
private Long id;
|
||||
|
||||
@@ -2,8 +2,12 @@ package org.agt.module.license.controller.admin.report.vo;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.alibaba.excel.annotation.write.style.ContentStyle;
|
||||
import com.alibaba.excel.enums.BooleanEnum;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import org.agt.framework.excel.core.annotations.DictFormat;
|
||||
import org.agt.framework.excel.core.convert.DictConvert;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
@@ -14,36 +18,48 @@ import java.util.List;
|
||||
public class ReportProgressProjectRespVO {
|
||||
|
||||
@Schema(description = "主键", requiredMode = Schema.RequiredMode.REQUIRED, example = "4294")
|
||||
@ExcelProperty("主键")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "项目ID", example = "18334")
|
||||
@ExcelProperty("项目ID")
|
||||
private Long projectId;
|
||||
|
||||
@Schema(description = "客户名称")
|
||||
@ExcelProperty("客户名称")
|
||||
private String customerName;
|
||||
|
||||
@Schema(description = "项目名称", example = "18334")
|
||||
@ExcelProperty("项目名称")
|
||||
private String projectName;
|
||||
|
||||
@Schema(description = "项目状态", example = "18334")
|
||||
@ExcelProperty(value = "项目状态", converter = DictConvert.class)
|
||||
@DictFormat("lic_project_status")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description = "商务状态", example = "18334")
|
||||
@ExcelProperty(value = "商务状态", converter = DictConvert.class)
|
||||
@DictFormat("lic_business_status")
|
||||
private Integer businessStatus;
|
||||
|
||||
@Schema(description = "serialNo", example = "随便")
|
||||
@ExcelProperty("SN")
|
||||
private String serialNo;
|
||||
|
||||
@Schema(description = "业务负责人")
|
||||
@ExcelProperty("业务负责人")
|
||||
private String businessOwnerName;
|
||||
|
||||
@Schema(description = "技术负责人1")
|
||||
@ExcelProperty("技术负责人1")
|
||||
private String technicalOwnerAName;
|
||||
|
||||
@Schema(description = "技术负责人2")
|
||||
@ExcelProperty("技术负责人2")
|
||||
private String technicalOwnerBName;
|
||||
|
||||
@Schema(description = "客户名称")
|
||||
private String customerName;
|
||||
@Schema(description = "项目开始时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("项目开始时间")
|
||||
private LocalDateTime startTime;
|
||||
|
||||
@Schema(description = "用户ID", example = "30248")
|
||||
@ExcelProperty("用户ID")
|
||||
@@ -53,25 +69,22 @@ public class ReportProgressProjectRespVO {
|
||||
@ExcelProperty("父ID")
|
||||
private Long parentId;
|
||||
|
||||
@Schema(description = "评论用户")
|
||||
@ExcelProperty("处理人")
|
||||
private String author;
|
||||
|
||||
@Schema(description = "内容")
|
||||
@ExcelProperty("内容")
|
||||
@ExcelProperty("进展记录")
|
||||
@ContentStyle(wrapped = BooleanEnum.TRUE)
|
||||
private String content;
|
||||
|
||||
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Schema(description = "项目开始时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("项目开始时间")
|
||||
private LocalDateTime startTime;
|
||||
|
||||
@Schema(description = "更新时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||
@ExcelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@Schema(description = "评论用户")
|
||||
private String author;
|
||||
|
||||
@Schema(description = "评论用户头像")
|
||||
private String avatar;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user