using System;
using SqlSugar;

namespace MDL.Models
{
    [SugarTable("tag_instances")]
    public class TagInstanceEntity
    {
        [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        public long Id { get; set; }

        [SugarColumn(Length = 50, IsNullable = false)]
        public string TagType { get; set; }

        [SugarColumn(IsNullable = false)]
        public int TemplateId { get; set; }

        [SugarColumn(Length = 100, IsNullable = false)]
        public string NeutralWaybillNumber { get; set; }

        [SugarColumn(IsNullable = false)]
        public int CustomerId { get; set; }

        [SugarColumn(Length = 20, DefaultValue = "ACTIVE")]
        public string Status { get; set; } = "ACTIVE";

        [SugarColumn(IsNullable = false)]
        public DateTime TriggerTime { get; set; }

        [SugarColumn(IsNullable = false, DefaultValue = "CURRENT_TIMESTAMP")]
        public DateTime CreatedAt { get; set; } = DateTime.Now;

        [SugarColumn(IsNullable = false, DefaultValue = "CURRENT_TIMESTAMP")]
        public DateTime UpdatedAt { get; set; } = DateTime.Now;
    }
}
