package com.qqchen.deploy.backend.deploy.query;

import com.qqchen.deploy.backend.deploy.enums.ExternalSystemSyncStatus;
import com.qqchen.deploy.backend.deploy.enums.JenkinsSyncType;
import com.qqchen.deploy.backend.framework.annotation.QueryField;
import com.qqchen.deploy.backend.framework.enums.QueryType;
import com.qqchen.deploy.backend.framework.query.BaseQuery;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;

/**
 * Jenkin同步日志查询对象
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class JenkinsSyncHistoryQuery extends BaseQuery {

    @QueryField(field = "end_time")
    private LocalDateTime endTime;

    @QueryField(field = "error_message", type = QueryType.LIKE)
    private String errorMessage;

    @QueryField(field = "external_system_id")
    private Long externalSystemId;

    @QueryField(field = "start_time")
    private LocalDateTime startTime;

    @QueryField(field = "status", type = QueryType.LIKE)
    private ExternalSystemSyncStatus status;

    @QueryField(field = "sync_type", type = QueryType.LIKE)
    private JenkinsSyncType syncType;

}