package org.dromara.mall.trade.domain.bo;

import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.Max;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.mall.trade.domain.MallOrderEvaluate;

/**
 * 订单评价业务对象 mall_order_evaluate
 *
 * @author pengles
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = MallOrderEvaluate.class, reverseConvertGenerate = false)
public class MallOrderEvaluateBo extends BaseEntity {

    /**
     * 评价ID
     */
    private Long id;

    /**
     * 订单ID
     */
    @NotNull(message = "订单ID不能为空")
    private Long orderId;

    /**
     * 订单号
     */
    private String orderNo;

    /**
     * 订单明细ID
     */
    @NotNull(message = "订单明细ID不能为空")
    private Long orderItemId;

    /**
     * 商品ID
     */
    private Long productId;

    /**
     * SKU ID
     */
    private Long skuId;

    /**
     * 用户ID
     */
    private Long userId;

    /**
     * 评分(1-5)
     */
    @NotNull(message = "评分不能为空")
    @Min(value = 1, message = "评分不能小于1")
    @Max(value = 5, message = "评分不能大于5")
    private Integer score;

    /**
     * 评价内容
     */
    private String content;

    /**
     * 评价图片(JSON数组)
     */
    private String images;

    /**
     * 回复内容
     */
    private String replyContent;

    /**
     * 状态(0待审核 1已通过 2已驳回)
     */
    private Integer status;

}
