package com.lesingle.modules.sys.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.lesingle.common.entity.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 租户实体
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("t_sys_tenant")
@Schema(description = "系统租户实体")
public class SysTenant extends BaseEntity {

    @Schema(description = "租户名称")
    private String name;

    @Schema(description = "租户编码（唯一，用于访问链接）")
    private String code;

    @Schema(description = "租户域名（可选）")
    private String domain;

    @Schema(description = "租户描述")
    private String description;

    @Schema(description = "是否为超级租户：0-否，1-是")
    @TableField("is_super")
    private Integer isSuper;

    @Schema(description = "租户类型", allowableValues = {"platform", "library", "kindergarten", "school", "institution", "other"})
    @TableField("tenant_type")
    private String tenantType;
}
