package com.qqchen.deploy.backend.deploy.entity;

import com.qqchen.deploy.backend.deploy.enums.DevelopmentLanguageTypeEnum;
import com.qqchen.deploy.backend.framework.domain.Entity;
import jakarta.persistence.Column;
import jakarta.persistence.Table;
import lombok.Data;
import lombok.EqualsAndHashCode;


/**
 * 应用实体
 */
@Data
@EqualsAndHashCode(callSuper = true)
@jakarta.persistence.Entity
@Table(name = "deploy_application")
public class Application extends Entity<Long> {

    /**
     * 应用编码
     */
    @Column(name = "app_code", nullable = false)
    private String appCode;

    /**
     * 应用名称
     */
    @Column(name = "app_name", nullable = false)
    private String appName;

    /**
     * 应用描述
     */
    @Column(name = "app_desc")
    private String appDesc;


    /**
     * 开发语言
     */
    @Column(name = "language")
    private DevelopmentLanguageTypeEnum language;

    @Column(name = "external_system_id", nullable = false)
    private Long externalSystemId;

    /**
     * 代码仓库组ID
     */
    @Column(name = "repo_group_id", nullable = false)
    private Long repoGroupId;

    /**
     * 代码仓库项目ID
     */
    @Column(name = "repo_project_id", nullable = false)
    private Long repoProjectId;

    /**
     * 项目组ID
     */
    @Column(name = "project_group_id", nullable = false)
    private Long projectGroupId;

    /**
     * 排序号
     */
    @Column(name = "sort", nullable = false)
    private Integer sort;

    /**
     * 应用状态
     */
    @Column(nullable = false)
    private Boolean enabled = true;

}