package com.ruoyi.ss.ad.domain;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.valid.EnumValid;
import com.ruoyi.ss.ad.domain.enums.AdUrlType;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * 广告对象 ss_ad
 *
 * @author ruoyi
 * @date 2024-05-11
 */
@Data
public class Ad extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    @ApiModelProperty("广告ID")
    private Long adId;

    @Excel(name = "广告类型 1：活动推广")
    @ApiModelProperty("广告类型 1：活动推广")
    private String type;

    @Excel(name = "广告图片")
    @ApiModelProperty("广告图片")
    private String picture;

    @Excel(name = "跳转链接")
    @ApiModelProperty("跳转链接")
    private String url;

    @Excel(name = "跳转链接类型")
    @ApiModelProperty("跳转链接类型，1外链跳转，2站内跳转")
    @EnumValid(
            clazz = AdUrlType.class,
            method = "getType",
            message = "非法的跳转链接类型"
    )
    private String urlType;
}
