package com.ruoyi.frequency.mallrefund.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.frequency.mallordergoods.entity.MallOrderGoods;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 订单退款对象 mall_refund
 *
 * @author liwenlong
 * @date 2024-01-25
 */
@Data
@Accessors(chain = true)
@TableName("mall_refund")
public class MallRefund extends BaseEntity
{
    private static final long serialVersionUID = 1L;


    @ApiModelProperty("主键id")
    private Long id;

    @ApiModelProperty("删除标志 1正常 删除 3 禁用")
    private Integer delFlag;

    @ApiModelProperty("订单id")
    @Excel(name = "订单id")
    private Long orderId;

    @ApiModelProperty("当前退款流程 当refund_type=1时，1 申请退款 2 商家同意退款 3 商家拒绝退款 ；当refund_type为2时，1申请退款退货，2商家同意退款退货，3 用户发货 4 商家确认收货 5 商家拒绝退款退货")
    @Excel(name = "当前退款流程 当refund_type=1时，1 申请退款 2 商家同意退款 3 商家拒绝退款 ；当refund_type为2时，1申请退款退货，2商家同意退款退货，3 用户发货 4 商家确认收货 5 商家拒绝退款退货")
    private Integer status;

    @ApiModelProperty("1 退款 2 退款退货")
    @Excel(name = "1 退款 2 退款退货")
    private Integer refundType;

    @ApiModelProperty("退货物流单号")
    @Excel(name = "退货物流单号")
    private String comCourierId;

    @ApiModelProperty("退货物流公司编码")
    @Excel(name = "退货物流公司编码")
    private String comLogisticsCode;

    @ApiModelProperty("退货物流公司")
    @Excel(name = "退货物流公司")
    private String comLogistics;

    @ApiModelProperty("申请原因")
    @Excel(name = "申请原因")
    private String refundReason;

    @ApiModelProperty("申请配图")
    @Excel(name = "申请配图")
    private String refundImages;

    @ApiModelProperty("商家拒绝原因")
    @Excel(name = "商家拒绝原因")
    private String refuseReason;

    @ApiModelProperty("退款说明")
    @Excel(name = "退款说明")
    private String refundExplain;

    @ApiModelProperty("审核时间")
    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date checkTime;

    @ApiModelProperty("商家id")
    @Excel(name = "商家id")
    private Long storeId;

    @ApiModelProperty("订单类型 1 普通订单")
    @Excel(name = "订单类型 1 普通订单")
    private Integer orderType;

    @ApiModelProperty("商品退款数量")
    @Excel(name = "商品退款数量")
    private Long refundNum;

    @ApiModelProperty("退款金额")
    @Excel(name = "退款金额")
    private BigDecimal refundPrice;

    @ApiModelProperty("售后确认收货时间")
    @Excel(name = "售后确认收货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date affirmTime;

    @ApiModelProperty("订单商品")
    @TableField(exist = false)
    private List<MallOrderGoods> orderGoodsList;

}
