diff --git a/Mango.Nop.Core/Dtos/ModelDtoBase.cs b/Mango.Nop.Core/Dtos/ModelDtoBase.cs index b6ac8a8..25cbd62 100644 --- a/Mango.Nop.Core/Dtos/ModelDtoBase.cs +++ b/Mango.Nop.Core/Dtos/ModelDtoBase.cs @@ -1,4 +1,5 @@ -using Nop.Core; +using AyCode.Core.Interfaces; +using Nop.Core; namespace Mango.Nop.Core.Dtos; diff --git a/Mango.Nop.Core/Entities/MgStockTaking.cs b/Mango.Nop.Core/Entities/MgStockTaking.cs index 658c88d..dce99f7 100644 --- a/Mango.Nop.Core/Entities/MgStockTaking.cs +++ b/Mango.Nop.Core/Entities/MgStockTaking.cs @@ -9,6 +9,8 @@ public interface IMgStockTaking : IEntityInt, ITimeStampInfo { public DateTime StartDateTime { get; set; } public bool IsClosed { get; set; } + + public bool IsReadyForClose(); } public abstract class MgStockTaking : MgEntityBase, IMgStockTaking where TStockTakingItem : class, IMgStockTakingItem @@ -16,6 +18,8 @@ public abstract class MgStockTaking : MgEntityBase, IMgStockTa public DateTime StartDateTime { get; set; } public bool IsClosed { get; set; } + public abstract bool IsReadyForClose(); + [Association(ThisKey = nameof(Id), OtherKey = nameof(IMgStockTakingItem.StockTakingId), CanBeNull = true)] public List? StockTakingItems { get; set; }