namespace Admin.NET.Plugin.AiDOP.Entity.S0.Sales;
///
/// 订单优先级配置(复刻 PriorityCode)
///
[SugarTable("PriorityCode", "订单优先级配置(复刻 PriorityCode)")]
public class AdoS0PriorityCode
{
[SugarColumn(ColumnName = "rec_id", ColumnDescription = "主键", IsPrimaryKey = true, IsIdentity = true, ColumnDataType = "bigint")]
public long Id { get; set; }
[SugarColumn(ColumnName = "company_ref_id", ColumnDescription = "关联公司 ID", ColumnDataType = "bigint")]
public long CompanyRefId { get; set; }
[SugarColumn(ColumnName = "factory_ref_id", ColumnDescription = "关联工厂 ID", ColumnDataType = "bigint")]
public long FactoryRefId { get; set; }
[SugarColumn(ColumnName = "domain_code", ColumnDescription = "工厂域编码", Length = 50, IsNullable = true)]
public string? DomainCode { get; set; }
[SugarColumn(ColumnName = "descr", ColumnDescription = "名称", Length = 200)]
public string Descr { get; set; } = string.Empty;
[SugarColumn(ColumnName = "value", ColumnDescription = "工单表字段", Length = 200, IsNullable = true)]
public string? Value { get; set; }
[SugarColumn(ColumnName = "priority", ColumnDescription = "优先级")]
public int Priority { get; set; }
/// 源系统 OrderBy:0=倒序,非0=正序
[SugarColumn(ColumnName = "order_by_code", ColumnDescription = "排序方式编码")]
public int OrderByCode { get; set; } = 1;
[SugarColumn(ColumnName = "source_table", ColumnDescription = "来源表", Length = 200, IsNullable = true)]
public string? SourceTable { get; set; }
[SugarColumn(ColumnName = "source_column", ColumnDescription = "来源表字段", Length = 200, IsNullable = true)]
public string? SourceColumn { get; set; }
[SugarColumn(ColumnName = "source_type", ColumnDescription = "来源表字段类型", Length = 100, IsNullable = true)]
public string? SourceType { get; set; }
[SugarColumn(ColumnName = "source_id", ColumnDescription = "来源表关联字段", Length = 200, IsNullable = true)]
public string? SourceId { get; set; }
[SugarColumn(ColumnName = "value_type", ColumnDescription = "工单表字段类型", Length = 100, IsNullable = true)]
public string? ValueType { get; set; }
[SugarColumn(ColumnName = "value_id", ColumnDescription = "工单表关联字段", Length = 200, IsNullable = true)]
public string? ValueId { get; set; }
[SugarColumn(ColumnName = "is_active", ColumnDescription = "是否生效", ColumnDataType = "boolean")]
public bool IsActive { get; set; } = true;
[SugarColumn(ColumnName = "create_user", ColumnDescription = "创建人", Length = 100, IsNullable = true)]
public string? CreateUser { get; set; }
[SugarColumn(ColumnName = "create_time", ColumnDescription = "创建时间")]
public DateTime CreateTime { get; set; } = DateTime.Now;
[SugarColumn(ColumnName = "update_user", ColumnDescription = "更新人", Length = 100, IsNullable = true)]
public string? UpdateUser { get; set; }
[SugarColumn(ColumnName = "update_time", ColumnDescription = "更新时间", IsNullable = true)]
public DateTime? UpdateTime { get; set; }
/// 列表展示:正序/倒序(不落库)
[SugarColumn(IsIgnore = true)]
public string? OrderByText { get; set; }
}