Files
WMSlite/WmsLite.Api/Models/InventoryTransaction.cs
T
zhougfandCursor fa1b286463 Add WmsLite monorepo with JWT auth, tenant context, and project READMEs.
Implement API security baseline (sys_user, JWT, audit fields, transactions,
unique constraints) and Web real login with 401 handling. Document setup
and development workflows in root, WmsLite.Api, and WmsLite.Web README files.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-24 14:17:47 +08:00

71 lines
2.7 KiB
C#

using System.Collections.Generic;
using SqlSugar;
using WmsLite.Api.Enums;
namespace WmsLite.Api.Models;
[SugarTable("inventory_transaction")]
public class InventoryTransaction : BaseEntity
{
[SugarColumn(ColumnName = "inventory_id", IsNullable = false)]
public long InventoryId { get; set; }
[SugarColumn(ColumnName = "movement_type", IsNullable = false)]
public InventoryMovementType MovementType { get; set; }
[SugarColumn(ColumnName = "inventory_status", IsNullable = false)]
public InventoryStatus InventoryStatus { get; set; }
[SugarColumn(ColumnName = "biz_no", Length = 128, IsNullable = true)]
public string? BizNo { get; set; }
[SugarColumn(ColumnName = "before_qty", IsNullable = false)]
public decimal BeforeQty { get; set; }
[SugarColumn(ColumnName = "after_qty", IsNullable = false)]
public decimal AfterQty { get; set; }
[SugarColumn(ColumnName = "before_pending_inbound_qty", IsNullable = false)]
public decimal BeforePendingInboundQty { get; set; }
[SugarColumn(ColumnName = "after_pending_inbound_qty", IsNullable = false)]
public decimal AfterPendingInboundQty { get; set; }
[SugarColumn(ColumnName = "before_pending_outbound_qty", IsNullable = false)]
public decimal BeforePendingOutboundQty { get; set; }
[SugarColumn(ColumnName = "after_pending_outbound_qty", IsNullable = false)]
public decimal AfterPendingOutboundQty { get; set; }
[SugarColumn(ColumnName = "before_frozen_qty", IsNullable = false)]
public decimal BeforeFrozenQty { get; set; }
[SugarColumn(ColumnName = "after_frozen_qty", IsNullable = false)]
public decimal AfterFrozenQty { get; set; }
[SugarColumn(ColumnName = "change_qty", IsNullable = false)]
public decimal ChangeQty { get; set; }
[SugarColumn(ColumnName = "material_code", Length = 64, IsNullable = true)]
public string? MaterialCode { get; set; }
[SugarColumn(ColumnName = "container_code", Length = 64, IsNullable = true)]
public string? ContainerCode { get; set; }
/// <summary>流水快照。</summary>
[SugarColumn(ColumnName = "warehouse_code", Length = 64, IsNullable = false)]
public string WarehouseCode { get; set; } = string.Empty;
[SugarColumn(ColumnName = "area_code", Length = 64, IsNullable = false)]
public string AreaCode { get; set; } = string.Empty;
[SugarColumn(ColumnName = "zone_code", Length = 64, IsNullable = false)]
public string ZoneCode { get; set; } = string.Empty;
[SugarColumn(ColumnName = "location_code", Length = 64, IsNullable = true)]
public string? LocationCode { get; set; }
[SugarColumn(ColumnName = "attrs", IsJson = true, ColumnDataType = "jsonb", IsNullable = true)]
public Dictionary<string, object>? Attrs { get; set; }
}