package com.ruoyi.business.domain;

import java.io.Serializable;
import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.experimental.Accessors;

/**
 * 对外服务授权对象 b_service_grant
 * 
 * @author wzq
 * @date 2024-01-10
 */
@Builder
@Data
@NoArgsConstructor
@AllArgsConstructor
@JsonIgnoreProperties(ignoreUnknown = true)
@TableName("b_service_grant")
@Accessors(chain = true)
public class ServiceGrant implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * $column.columnComment
     */
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @JsonSerialize(using= ToStringSerializer.class)
    private Long id;

    /**
     * 客户端id
     */
    @TableField("client_id")
    @JsonSerialize(using= ToStringSerializer.class)
    private String clientId;

    /**
     * 所属系统
     */
    @TableField("belong_system")
    private String belongSystem;

    /**
     * 对外资源id
     */
    @TableField("service_business_id")
    @JsonSerialize(using= ToStringSerializer.class)
    private Long serviceBusinessId;

    /**
     * 备注
     */
    @TableField("remark")
    private String remark;

    /**
     * $column.columnComment
     */
    @TableField("dept_id_path")
    private String deptIdPath;

    /**
     * $column.columnComment
     */
    @TableField("dept_name")
    private String deptName;

    /**
     * $column.columnComment
     */
    @TableField("create_by")
    private String createBy;

    /**
     * $column.columnComment
     */
    @TableField("create_user_id")
    private String createUserId;

    /**
     * $column.columnComment
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField("create_time")
    private Date createTime;

    /**
     * $column.columnComment
     */
    @TableField("update_by")
    private String updateBy;

    /**
     * $column.columnComment
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField("update_time")
    private Date updateTime;

    /**
     * $column.columnComment
     */
    @TableField("delete_by")
    private String deleteBy;

    /**
     * $column.columnComment
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField("delete_time")
    private Date deleteTime;

    /**
     * 0未删除，1已删除
     */
    @TableField("delete_flag")
    @TableLogic
    private String deleteFlag;


}
