|
|
@@ -1,7 +1,11 @@
|
|
|
package com.izouma.wenlvju.dto;
|
|
|
|
|
|
+import cn.hutool.core.bean.BeanUtil;
|
|
|
+import cn.hutool.core.util.ObjectUtil;
|
|
|
+import com.alibaba.excel.annotation.ExcelProperty;
|
|
|
+import com.izouma.wenlvju.domain.Record;
|
|
|
+import com.izouma.wenlvju.domain.RecordSpecialty;
|
|
|
import io.swagger.annotations.ApiModel;
|
|
|
-import io.swagger.annotations.ApiModelProperty;
|
|
|
import lombok.AllArgsConstructor;
|
|
|
import lombok.Builder;
|
|
|
import lombok.Data;
|
|
|
@@ -13,73 +17,84 @@ import java.time.LocalDate;
|
|
|
@Builder
|
|
|
@AllArgsConstructor
|
|
|
@NoArgsConstructor
|
|
|
-@ApiModel("备案管理")
|
|
|
+@ApiModel(value = "备案管理")
|
|
|
public class RecordDTO {
|
|
|
- @ApiModelProperty(value = "考级活动名称")
|
|
|
+ @ExcelProperty(value = "考级活动名称")
|
|
|
private String examinationName;
|
|
|
|
|
|
- @ApiModelProperty(value = "考级活动时间")
|
|
|
+ @ExcelProperty(value = "考级活动时间")
|
|
|
private LocalDate examinationStartTime;
|
|
|
|
|
|
- @ApiModelProperty(value = "考级活动时间")
|
|
|
+ @ExcelProperty(value = "考级活动时间")
|
|
|
private LocalDate examinationEndTime;
|
|
|
|
|
|
- @ApiModelProperty(value = "考级机构名称")
|
|
|
+ @ExcelProperty(value = "考级机构名称")
|
|
|
private String examinationAgency;
|
|
|
|
|
|
- @ApiModelProperty(value = "单位类别")
|
|
|
+ @ExcelProperty(value = "单位类别")
|
|
|
private String category;
|
|
|
|
|
|
- @ApiModelProperty(value = "承办单位名称")
|
|
|
+ @ExcelProperty(value = "承办单位名称")
|
|
|
private String organizer;
|
|
|
|
|
|
- @ApiModelProperty(value = "统一社会信用代码")
|
|
|
+ @ExcelProperty(value = "统一社会信用代码")
|
|
|
private String uscc;
|
|
|
|
|
|
+ @ExcelProperty(value = "考级地址")
|
|
|
private String district;
|
|
|
|
|
|
- @ApiModelProperty(value = "考级详细地址")
|
|
|
+ @ExcelProperty(value = "考级详细地址")
|
|
|
private String examinationAddress;
|
|
|
|
|
|
- @ApiModelProperty(value = "考场数量")
|
|
|
+ @ExcelProperty(value = "考场数量")
|
|
|
private int examCenterQuantity;
|
|
|
|
|
|
- @ApiModelProperty(value = "报考人数")
|
|
|
+ @ExcelProperty(value = "报考人数")
|
|
|
private int examQuantity;
|
|
|
|
|
|
- @ApiModelProperty(value = "考官人数")
|
|
|
+ @ExcelProperty(value = "考官人数")
|
|
|
private int examinerQuantity;
|
|
|
|
|
|
- @ApiModelProperty(value = "考点负责人名称")
|
|
|
+ @ExcelProperty(value = "考点负责人名称")
|
|
|
private String examOwner;
|
|
|
|
|
|
- @ApiModelProperty(value = "考点负责人手机号")
|
|
|
+ @ExcelProperty(value = "考点负责人手机号")
|
|
|
private String examOwnerPhone;
|
|
|
|
|
|
- @ApiModelProperty(value = "安全负责人名称")
|
|
|
+ @ExcelProperty(value = "安全负责人名称")
|
|
|
private String securityOwner;
|
|
|
|
|
|
- @ApiModelProperty(value = "安全负责人手机号")
|
|
|
+ @ExcelProperty(value = "安全负责人手机号")
|
|
|
private String securityOwnerPhone;
|
|
|
|
|
|
- @ApiModelProperty(value = "备案时间")
|
|
|
+ @ExcelProperty(value = "备案时间")
|
|
|
private LocalDate recordTime;
|
|
|
|
|
|
- @ApiModelProperty(value = "考试简章")
|
|
|
+ @ExcelProperty(value = "考试简章")
|
|
|
private String examinationGuide;
|
|
|
|
|
|
- @ApiModelProperty(value = "专业名称")
|
|
|
+ @ExcelProperty(value = "考级专业名称")
|
|
|
private String name;
|
|
|
|
|
|
- @ApiModelProperty(value = "专业代码")
|
|
|
+ @ExcelProperty(value = "考级专业代码")
|
|
|
private String code;
|
|
|
|
|
|
- @ApiModelProperty(value = "总级数")
|
|
|
+ @ExcelProperty(value = "考级专业总级数")
|
|
|
private String level;
|
|
|
|
|
|
- @ApiModelProperty(value = "考场数量")
|
|
|
+ @ExcelProperty(value = "考级专业考场数量")
|
|
|
private int numOfExam;
|
|
|
|
|
|
- @ApiModelProperty(value = "考官人数")
|
|
|
+ @ExcelProperty(value = "考级专业考官人数")
|
|
|
private int speExaQuantity;
|
|
|
+
|
|
|
+ public RecordDTO(Record record, RecordSpecialty specialty) {
|
|
|
+ BeanUtil.copyProperties(record, this);
|
|
|
+ this.examinerQuantity = record.getExaminerQuantity();
|
|
|
+
|
|
|
+ if (ObjectUtil.isNotEmpty(specialty)){
|
|
|
+ BeanUtil.copyProperties(specialty, this);
|
|
|
+ this.speExaQuantity = specialty.getExaminerQuantity();
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|