package com.czg.account.dto;

import com.alibaba.fastjson2.annotation.JSONField;
import com.czg.validator.group.DefaultGroup;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Null;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 图库
 *
 * @author Tankaikai tankaikai@aliyun.com
 * @since 1.0 2025-02-26
 */
@Data
public class PictureGalleryDTO implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @Null(message = "ID必须为空", groups = DefaultGroup.class)
    private Long id;
    /**
     * 店铺id
     */
    private Long shopId;
    /**
     * 图片分类id
     */
    @NotNull(message = "图片分类id不能为空", groups = DefaultGroup.class)
    private Long pictureClassifyId;
    /**
     * 图片URL地址
     */
    @NotBlank(message = "图片URL地址不能为空", groups = DefaultGroup.class)
    private String url;
    /**
     * 创建时间
     */
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;
    /**
     * 逻辑删除 1-是 0-否
     */
    private Integer isDel;

}