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

import com.qqchen.deploy.backend.framework.domain.Entity;
import jakarta.persistence.*;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.time.LocalDateTime;

/**
 * Jenkins工作实体
 */
@Data
@EqualsAndHashCode(callSuper = true)
@jakarta.persistence.Entity
@Table(name = "deploy_jenkins_job")
public class JenkinsJob extends Entity<Long> {

    @Column(name = "buildable")
    private Boolean buildable;

    @Column(name = "description")
    private String description;

    @Column(name = "job_name", nullable = false)
    private String jobName;

    @Column(name = "job_url", nullable = false)
    private String jobUrl;

    @Column(name = "next_build_number")
    private Integer nextBuildNumber;

    @Column(name = "last_build_number")
    private Integer lastBuildNumber;

    @Column(name = "last_build_status")
    private String lastBuildStatus;

    @Column(name = "health_report_score")
    private Integer healthReportScore;

    @Column(name = "last_build_time")
    private LocalDateTime lastBuildTime;

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

    @Column(name = "view_id", nullable = false)
    private Long viewId;

} 