package com.yuchen.saas.payment.api.dto.order;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

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

/**
 * @Author 蔡文强
 * @Date 2024/01/23 10:56
 * @Description 申诉处理DTO
 */
@Data
@ApiModel(value = "OrderRefundAppealHandleDTO对象", description = "申诉处理DTO")
public class OrderRefundAppealHandleDTO {

    /**
     * 主键ID
     */
    @ApiModelProperty(name = "id", value = "主键ID")
    @NotNull(message = "主键ID不能为空")
    private Long id;
    /**
     * 申诉状态(1:待处理 2:已通过 3:未通过 4已取消)
     */
    @ApiModelProperty(name = "appealStatus", value = "申诉状态(1:待处理 2:已通过 3:未通过 4已取消)")
    @NotNull(message = "申诉状态不能为空")
    private Integer appealStatus;
    /**
     * 处理说明
     */
    @ApiModelProperty(name = "handleDesc", value = "处理说明")
    @NotBlank(message = "处理说明不能为空")
    private String handleDesc;
    /**
     * 退款金额
     */
    @ApiModelProperty(name = "refundAmount", value = "退款金额")
    private Long refundAmount;

    @ApiModelProperty(name = "refundCostDetail", value = "退款金额明细（多费用项）")
    private List<OrderRefundAppealHandleDTO.RefundCostDetail> refundCostDetail;

    @Data
    public static class RefundCostDetail {
        @ApiModelProperty(name = "itemName", value = "费用项目名称")
        private String itemName;

        @ApiModelProperty(name = "itemNo", value = "费用编号")
        private String itemNo;

        @ApiModelProperty(name = "itemRefundCost", value = "退款费用项目金额 单位 分")
        private Long itemRefundCost;

        @ApiModelProperty(name = "refundCost", value = "可退金额 单位 分")
        private Long refundCost;
    }

}
