package com.yuchen.saas.park.api.dto.property;


import com.yuchen.saas.park.api.entity.property.PropertyPayReductionDetail;
import com.yuchen.saas.park.api.entity.property.PropertyPayReductionHouseLog;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;


@Data
@ApiModel(value="PropertyPayReductionAddDto", description="新增")
public class PropertyPayReductionAddDto {

    @ApiModelProperty(name = "id", value = "id")
    private Long id;

    @NotNull
    @ApiModelProperty(name = "parkId", value = "园区id")
    private Long parkId;

    @NotBlank
    @ApiModelProperty(name = "reductionName", value = "减免活动名称")
    private String reductionName;

    @NotEmpty
    @ApiModelProperty(name = "payReductionHouseList", value = "活动范围")
    private List<PropertyPayReductionHouseLog> payReductionHouseList;


    @ApiModelProperty(name = "reductionTimeStart", value = "减免开始时间")
    private Date reductionTimeStart;

    @ApiModelProperty(name = "reductionTimeEnd", value = "减免结束时间")
    private Date reductionTimeEnd;

    @NotNull
    @Range(min = 1, max = 2)
    @ApiModelProperty(name = "reductionType", value = "减免方式:1交满指定月数费用,2交清指定时间内费用")
    private Integer reductionType;

    @NotNull
    @Range(min = 1, max = 3)
    @ApiModelProperty(name = "reductionDetailType", value = "减免详情:1指定减免月数,2减免单价,3减免总金额")
    private Integer reductionDetailType;

    @NotEmpty
    @ApiModelProperty(name = "payReductionDetailList", value = "减免详情明细")
    private List<PropertyPayReductionDetail> payReductionDetailList;

    @NotNull
    @Range(min = 0, max = 1)
    @ApiModelProperty(name = "isPaidFee", value = "需不需要缴清费用,0不需要,1需要")
    private Integer isPaidFee;

    @ApiModelProperty(name = "remark", value = "备注")
    private String remark;

    @ApiModelProperty(name = "sourceText", value = "提交减免范围")
    private String sourceText;
}
