AdoS0ProcessFlowCard.cs 3.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. namespace Admin.NET.Plugin.AiDOP.Entity.S0.Manufacturing;
  2. /// <summary>
  3. /// 工序流转卡主数据(与工单控制参数 WorkOrdControl 语义区分)。
  4. /// </summary>
  5. [SugarTable("S0ProcessFlowCard", "工序流转卡主数据")]
  6. [SugarIndex("uk_S0ProcessFlowCard_factory_flowcard",
  7. nameof(TenantId), OrderByType.Asc, nameof(FactoryRefId), OrderByType.Asc, nameof(FlowCardNo), OrderByType.Asc, IsUnique = true)]
  8. public class AdoS0ProcessFlowCard : ITenantIdFilter
  9. {
  10. [SugarColumn(ColumnName = "rec_id", IsPrimaryKey = true, IsIdentity = true, ColumnDataType = "bigint")]
  11. public long Id { get; set; }
  12. [SugarColumn(ColumnName = "company_ref_id", ColumnDataType = "bigint")]
  13. public long CompanyRefId { get; set; }
  14. [SugarColumn(ColumnName = "factory_ref_id", ColumnDataType = "bigint")]
  15. public long FactoryRefId { get; set; }
  16. [SugarColumn(ColumnName = "domain_code", Length = 50, IsNullable = true)]
  17. public string? DomainCode { get; set; }
  18. [SugarColumn(ColumnName = "work_order_no", Length = 100)]
  19. public string WorkOrderNo { get; set; } = string.Empty;
  20. [SugarColumn(ColumnName = "work_order_batch_no", Length = 100, IsNullable = true)]
  21. public string? WorkOrderBatchNo { get; set; }
  22. [SugarColumn(ColumnName = "flow_card_no", Length = 100)]
  23. public string FlowCardNo { get; set; } = string.Empty;
  24. [SugarColumn(ColumnName = "nature", Length = 100, IsNullable = true)]
  25. public string? Nature { get; set; }
  26. [SugarColumn(ColumnName = "item_num", Length = 100)]
  27. public string ItemNum { get; set; } = string.Empty;
  28. [SugarColumn(ColumnName = "item_name", Length = 200, IsNullable = true)]
  29. public string? ItemName { get; set; }
  30. [SugarColumn(ColumnName = "drawing_no", Length = 100, IsNullable = true)]
  31. public string? DrawingNo { get; set; }
  32. [SugarColumn(ColumnName = "bom_version", Length = 50, IsNullable = true)]
  33. public string? BomVersion { get; set; }
  34. [SugarColumn(ColumnName = "routing_code", Length = 100, IsNullable = true)]
  35. public string? RoutingCode { get; set; }
  36. [SugarColumn(ColumnName = "remarks", Length = 500, IsNullable = true)]
  37. public string? Remarks { get; set; }
  38. [SugarColumn(ColumnName = "is_active", ColumnDataType = "boolean")]
  39. public bool IsActive { get; set; } = true;
  40. [SugarColumn(ColumnName = "create_user", Length = 100, IsNullable = true)]
  41. public string? CreateUser { get; set; }
  42. [SugarColumn(ColumnName = "create_time")]
  43. public DateTime CreateTime { get; set; } = DateTime.Now;
  44. [SugarColumn(ColumnName = "update_user", Length = 100, IsNullable = true)]
  45. public string? UpdateUser { get; set; }
  46. [SugarColumn(ColumnName = "update_time", IsNullable = true)]
  47. public DateTime? UpdateTime { get; set; }
  48. /// <summary>
  49. /// 租户Id。IsOnlyIgnoreUpdate=true:租户归属只在插入时按 AdoS0TenantScope 解析结果落定,
  50. /// 任何 UPDATE 都不得改写(与框架 EntityBase.TenantId 同口径),杜绝改单据时被搬到别的租户。
  51. /// </summary>
  52. [SugarColumn(ColumnName = "tenant_id", IsNullable = true, IsOnlyIgnoreUpdate = true)]
  53. public long? TenantId { get; set; }
  54. }