package com.usky.rule.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.Date;

/**
 * 对应表 rule_engine_log（规则执行日志）
 */
@Data
public class RuleEngineLog {
    private Long id;
    private Long projectId;
    private Long ruleEngineId;
    private String ruleEngineName;
    /** 自动触发 0：否 1：是 */
    private Byte autoTrigger;
    /** 触发类型 device/space/cron */
    private String triggerType;
    /** 执行动作 deviceControl/alarmEvent/workOrder */
    private String action;
    /** 日志数据 JSON */
    private String detail;
    private String content;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime time;
    private String updatedBy;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;
    private String createdBy;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /**
     * 租户号
     */
    private Integer tenantId;
}
