package com.ruoyi.syzy.dto;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.ruoyi.common.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.List;

@ApiModel("志愿填报提交数据")
@JsonInclude(JsonInclude.Include.NON_NULL)
public class SubmitWishRecordDTO implements java.io.Serializable {

    /**
     *
     */
    private static final long serialVersionUID = 1L;
    @ApiModelProperty("志愿表ID")
    private Long id;
    @ApiModelProperty("志愿表保存名称")
    private String name;
    @ApiModelProperty("填报批次")
    private Integer batch;
    @ApiModelProperty("填报批次")
    private String batchName;
    @ApiModelProperty("用户快照信息")
    private User userSnapshot;
    @ApiModelProperty("保存数据明细")
    private SubmitWishRecordDetail detail;

    public String getBatchName() {
        return batchName;
    }

    public void setBatchName(String batchName) {
        this.batchName = batchName;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getBatch() {
        return batch;
    }

    public void setBatch(Integer batch) {
        this.batch = batch;
    }

    public User getUserSnapshot() {
        return userSnapshot;
    }

    public void setUserSnapshot(User userSnapshot) {
        this.userSnapshot = userSnapshot;
    }

    public SubmitWishRecordDetail getDetail() {
        return detail;
    }

    public void setDetail(SubmitWishRecordDetail detail) {
        this.detail = detail;
    }

    @Data
    public static class User {
        String name;
        String sex;
        String examType;
        String provinceName;
        String examMajor;
        String examMajorName;
    }

    public static class SubmitWishRecordDetail {

        @ApiModelProperty("科类:文科,理科")
        private String mode;
        @ApiModelProperty("总分")
        private Float score;
        @ApiModelProperty("输入位次")
        private Integer seatInput;
        @ApiModelProperty("年度")
        private Integer year;
        @ApiModelProperty("填报批次详情")
        private SubmitWishRecordBatch batch;

        @JsonProperty("isMock")
        @ApiModelProperty("是否将年份显示为最新年份（如：2023年6月1日，" +
                "此时需要将模拟志愿计划的时间显示为2023，但实际没有2023年的数据时）")
        private Boolean isMock=false;

        public Boolean getIsMock() {
            return isMock;
        }

        public void setIsMock(Boolean mock) {
            isMock = mock;
        }

        public String getMode() {
            return mode;
        }

        public void setMode(String mode) {
            this.mode = mode;
        }

        public Integer getYear() {
            return year;
        }

        public void setYear(Integer year) {
            this.year = year;
        }

        public Float getScore() {
            return score;
        }

        public void setScore(Float score) {
            this.score = score;
        }

        public SubmitWishRecordBatch getBatch() {
            return batch;
        }

        public void setBatch(SubmitWishRecordBatch batch) {
            this.batch = batch;
        }

        public Integer getSeatInput() {
            return seatInput;
        }

        public void setSeatInput(Integer seatInput) {
            this.seatInput = seatInput;
        }
    }

    @Data
    public static class SubmitWishRecordBatch {
        @ApiModelProperty("批次")
        private Integer batch;
        List<String> highlightMajorIds;
        @ApiModelProperty("批次说明")
        private String name;
        @ApiModelProperty("文科分数，兼容")
        private String scorel;
        @ApiModelProperty("文科分数，兼容")
        private String score1;
        @ApiModelProperty("理科分数")
        private String score2;
        @ApiModelProperty("批次查询分数上限")
        private String scoreBatchLimit;
        @ApiModelProperty("投档分")
        private List<String> scores;
        @ApiModelProperty("是否推荐")
        private Boolean recommand;
        @ApiModelProperty("志愿明细")
        private List<SubmitWishRecordBatchWishes> wishes;
        @ApiModelProperty("排序序号类型（number,letter）")
        private String sort;
        @ApiModelProperty("志愿个数")
        private List<VoluntaryParamBatch> paramBatches;
    }

    @Data
    public static class SubmitWishRecordBatchWishes {
        @ApiModelProperty("第几志愿")
        private Integer index;
        @ApiModelProperty("志愿类型:0 冲刺,1 稳妥, 2保守")
        private Integer pickType;
        private String ranking;
        private String rankingOfEdu;
        @ApiModelProperty("志愿类型:冲刺,稳妥,保守")
        private String pickTypeComment;
        @ApiModelProperty("院校id")
        private Long universityId;
        @ApiModelProperty("jCode")
        @JsonProperty("jCode")
        private String jCode;
        @ApiModelProperty("院校投档线id")
        private Long submitId;
        @ApiModelProperty("专业组")
        private String collegeCode;
        @ApiModelProperty("院校编码")
        private String code;
        @ApiModelProperty("院校名称")
        private String name;
        @ApiModelProperty("院校特色")
        private String type;
        @ApiModelProperty("投档分")
        private String score;
        @ApiModelProperty("投档位次")
        private String seat;
        @ApiModelProperty("录取概率")
        private String enrollRatio;
        @ApiModelProperty("风险值")
        private String enrollRatioText;
        @ApiModelProperty("专业明细")
        private List<SubmitWishRecordBatchMarjors> marjors;
        @ApiModelProperty("是否服从")
        private Boolean assignment = Boolean.FALSE;
    }
    @Data
    public static class VoluntaryParamBatch {
        @ApiModelProperty("第几志愿")
        private Integer batch;
        @ApiModelProperty("专业组或院校专业类的数量")
        private Integer groups;
        @ApiModelProperty("专业的数量")
        private Integer profession;
    }

    public static class SubmitWishRecordBatchMarjors {
        @ApiModelProperty("顺序")
        private Integer index;
        @ApiModelProperty("专业id")
        private Long id;
        @ApiModelProperty("专业编码")
        private String code;
        @ApiModelProperty("志愿类型:0 冲刺,1 稳妥, 2保守")
        private Integer pickType;
        @ApiModelProperty("专业名称")
        private String name;
        @ApiModelProperty("录取概率")
        private String enrollRatio;
        @ApiModelProperty("风险值")
        private String enrollRatioText;
        @ApiModelProperty("大小分")
        private Boolean enrollFluctuate;

        public String getEnrollRatio() {
            return enrollRatio;
        }

        public void setEnrollRatio(String enrollRatio) {
            this.enrollRatio = enrollRatio;
        }

        public String getEnrollRatioText() {
            return enrollRatioText;
        }

        public void setEnrollRatioText(String enrollRatioText) {
            this.enrollRatioText = enrollRatioText;
        }

        public Integer getIndex() {
            return index;
        }

        public void setIndex(Integer index) {
            this.index = index;
        }

        public Long getId() {
            return id;
        }

        public void setId(Long id) {
            this.id = id;
        }

        public String getCode() {
            return code;
        }

        public void setCode(String code) {
            this.code = code;
        }

        public Integer getPickType() {
            return pickType;
        }

        public void setPickType(Integer pickType) {
            this.pickType = pickType;
        }

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public Boolean getEnrollFluctuate() {
            return enrollFluctuate;
        }

        public void setEnrollFluctuate(Boolean enrollFluctuate) {
            this.enrollFluctuate = enrollFluctuate;
        }
    }
}
