namespace MMDAL.DTO.InventoryReports { // Non-Moving / Obsolete Stock tile. Simplified port of legacy GB4's // StockPositionDAL.GetNonMovingReport + StockPositionQueryBuilder.GET_NON_MOVING_REPORT (see // /Users/venkatv/Downloads/VVMMBLLDAL/MMDAL/CustomCode/Stock/StockPositionDAL.cs:2364 and // StockPositionQueryBuilder.cs:4962). Deliberate scope trim from legacy: only the // LastTransactedDays staleness definition is ported (legacy also offered LastInward/ // LastOutward variants); only posted-value costing is used (legacy offered 5 cost-basis // switches: product-cost actual/standard, last-purchase-rate, PURCHASECOSTNLC, MRP-rate -- // those need VPRODUCTCOST/MPRICELIST semantics not yet verified live on this schema). The // stock-adjustment exclusion (BizTransactionClassId sentinels) IS ported -- legacy's own // comment flags it as load-bearing, not decorative. public class NonMovingReportDTO { public int ItemId { get; set; } public string ItemCode { get; set; } = string.Empty; public string ItemName { get; set; } = string.Empty; public int SKUId { get; set; } public string SKUCode { get; set; } = string.Empty; public string SKUName { get; set; } = string.Empty; public int ItemCategoryId { get; set; } public string ItemCategoryCode { get; set; } = string.Empty; public string ItemCategoryName { get; set; } = string.Empty; public decimal Stock { get; set; } public decimal StockValue { get; set; } // Ratio of stock quantity to stock value * 100, rounded to 4dp -- same formula as legacy, // kept for parity even though it reads oddly (it's stock/value, not value/stock). public decimal NonMovingPercent { get; set; } public DateTime? LastTransactedDate { get; set; } public int LastTransactedDays { get; set; } } }