namespace Admin.NET.Plugin.AiDOP.Entity.S8.Demo; /// /// ORDER-FLOW-BE-DEMO-DATASET-RESET-1 演示主表:S8 订单执行档案 demo 主数据。 /// 与真实业务订单(SeOrder/Order_*)完全解耦;仅供"订单执行档案"演示页面读取。 /// [SugarTable("ado_demo_order_flow", "演示订单执行档案主表(demo only,不与真实业务表混用)")] [SugarIndex("uk_demo_order_flow_so_no", nameof(SoNo), OrderByType.Asc, true)] [SugarIndex("idx_demo_order_flow_tenant_factory", nameof(TenantId), OrderByType.Asc, nameof(FactoryId), OrderByType.Asc, nameof(SortNo), OrderByType.Asc)] public class AdoDemoOrderFlow { [SugarColumn(ColumnName = "id", IsPrimaryKey = true, IsIdentity = false, ColumnDataType = "bigint")] public long Id { get; set; } [SugarColumn(ColumnName = "so_no", Length = 32)] public string SoNo { get; set; } = string.Empty; [SugarColumn(ColumnName = "product_name", Length = 128)] public string ProductName { get; set; } = string.Empty; [SugarColumn(ColumnName = "product_line", Length = 32)] public string ProductLine { get; set; } = string.Empty; [SugarColumn(ColumnName = "customer_name", Length = 128)] public string CustomerName { get; set; } = string.Empty; [SugarColumn(ColumnName = "customer_code", Length = 64)] public string CustomerCode { get; set; } = string.Empty; /// KA / SMB / MICRO。 [SugarColumn(ColumnName = "customer_type", Length = 8)] public string CustomerType { get; set; } = "KA"; [SugarColumn(ColumnName = "region", Length = 32)] public string Region { get; set; } = string.Empty; /// P1 / P2 / P3。 [SugarColumn(ColumnName = "priority", Length = 4)] public string Priority { get; set; } = "P2"; /// XX / YY / ZZ(与产品线对照)。 [SugarColumn(ColumnName = "material_code", Length = 8)] public string MaterialCode { get; set; } = "XX"; /// A / B / C。 [SugarColumn(ColumnName = "supplier_group", Length = 8)] public string SupplierGroup { get; set; } = "A"; /// completed / in_progress。 [SugarColumn(ColumnName = "workflow_status", Length = 16)] public string WorkflowStatus { get; set; } = "completed"; /// 5 阶段 key 之一:order_review / product_design / material_procurement / body_production / final_assembly_shipping。 [SugarColumn(ColumnName = "current_node_key", Length = 32)] public string CurrentNodeKey { get; set; } = "final_assembly_shipping"; [SugarColumn(ColumnName = "focus_node_key", Length = 32)] public string FocusNodeKey { get; set; } = "final_assembly_shipping"; [SugarColumn(ColumnName = "current_node_label", Length = 32)] public string CurrentNodeLabel { get; set; } = "总装发货"; /// green / yellow / red。 [SugarColumn(ColumnName = "node_status", Length = 8)] public string NodeStatus { get; set; } = "green"; [SugarColumn(ColumnName = "release_at")] public DateTime ReleaseAt { get; set; } [SugarColumn(ColumnName = "target_cycle_days", DecimalDigits = 1, Length = 6)] public decimal TargetCycleDays { get; set; } [SugarColumn(ColumnName = "current_cycle_days", DecimalDigits = 1, Length = 6, IsNullable = true)] public decimal? CurrentCycleDays { get; set; } [SugarColumn(ColumnName = "actual_cycle_days", DecimalDigits = 1, Length = 6, IsNullable = true)] public decimal? ActualCycleDays { get; set; } [SugarColumn(ColumnName = "node_variance_days", DecimalDigits = 1, Length = 6, IsNullable = true)] public decimal? NodeVarianceDays { get; set; } [SugarColumn(ColumnName = "cumulative_variance_days", DecimalDigits = 1, Length = 6, IsNullable = true)] public decimal? CumulativeVarianceDays { get; set; } [SugarColumn(ColumnName = "exception_count")] public int ExceptionCount { get; set; } [SugarColumn(ColumnName = "response_minutes", IsNullable = true)] public int? ResponseMinutes { get; set; } [SugarColumn(ColumnName = "processing_minutes", IsNullable = true)] public int? ProcessingMinutes { get; set; } [SugarColumn(ColumnName = "total_loss_minutes", IsNullable = true)] public int? TotalLossMinutes { get; set; } /// 待响应 / 处理中 / 已闭环。 [SugarColumn(ColumnName = "exception_status", Length = 16)] public string ExceptionStatus { get; set; } = "已闭环"; [SugarColumn(ColumnName = "sort_no")] public int SortNo { get; set; } [SugarColumn(ColumnName = "tenant_id", ColumnDataType = "bigint")] public long TenantId { get; set; } [SugarColumn(ColumnName = "factory_id", ColumnDataType = "bigint")] public long FactoryId { get; set; } [SugarColumn(ColumnName = "created_at")] public DateTime CreatedAt { get; set; } = DateTime.Now; [SugarColumn(ColumnName = "updated_at", IsNullable = true)] public DateTime? UpdatedAt { get; set; } [SugarColumn(ColumnName = "is_deleted", ColumnDataType = "boolean")] public bool IsDeleted { get; set; } }