Interface IEntityPeriodClosing
The system entity for a period closing, which ensures any transactions booked to this entity will occur in the gl after the latest closed period
See https://web.lemonedge.com/help/period-closings-view/ for more information
Inherited Members
System.IEquatable<LemonEdge.API.Core.IBaseEntity>.Equals(LemonEdge.API.Core.IBaseEntity)
System.ComponentModel.INotifyPropertyChanged.PropertyChanged
System.ComponentModel.INotifyPropertyChanging.PropertyChanging
Namespace: LemonEdge.API.Entities
Assembly: API.dll
Syntax
[EntityDefinition(EntityID.EntityPeriodClosings, "dbo.LT_EntityPeriodClosings", "EntityPeriodClosing", IsStandingDataEntity = false)]
[DefaultEntityIcon(ImageType.PeriodClosing)]
[MultipleUnique(new string[]{"PeriodClosedDate", "EntityID"}, AllowNullOrEmpty = false)]
public interface IEntityPeriodClosing : IBaseEntity, IEquatable<IBaseEntity>, INotifyPropertyChanged, INotifyPropertyChanging, ICloneableAsync, ICanTrackProperties
Properties
EntityID
[Key] Links to IObjectEntity. The globally unique id of the IObjectEntity that this period is now closed for
Declaration
[EntityProperty(SQLType.UniqueIdentifier, false)]
[EntityRelationship(EntityID.ObjectEntity, "ID", SingleJoinType.One, "ObjectEntity", "EntityPeriodClosings", DeleteWithRelationship = true, PartOfParentSet = true, LinkToItemInSet = false, InheritPermissions = true)]
[EntityDescription("The entity that this date is closing the gl period for.")]
Guid EntityID { get; set; }
Property Value
Type | Description |
---|---|
System.Guid |
PeriodClosedDate
The date that this Period closes on.
All Transactions booked to this Entity with a date equal to or less than this date will now be in a closed period.Any changes will cancel/correct to the next open financial period.
Declaration
[EntityProperty(SQLType.DateTimeOffset, false, IsDate = true)]
[EntityDescription("The date to close the gl period for. Any transactions with a financial date before this will be posted after this date now.")]
[Required]
[DatabasePropertyValidation("true", "(await Data.ExecuteQuery(Data.GetItems<LemonEdge.API.Entities.IEntityPeriodClosing>().Where(nameof(LemonEdge.API.Entities.IEntityPeriodClosing.EntityID), LemonEdge.Utils.Database.SQLOperator.Equals, ItemAs<LemonEdge.API.Entities.IEntityPeriodClosing>().EntityID).Where(nameof(LemonEdge.API.Entities.IEntityPeriodClosing.ID), LemonEdge.Utils.Database.SQLOperator.NotEquals, ItemAs<LemonEdge.API.Entities.IEntityPeriodClosing>().ID).Where(nameof(LemonEdge.API.Entities.IEntityPeriodClosing.PeriodClosedDate), LemonEdge.Utils.Database.SQLOperator.GreaterThanOrEqualTo, ItemAs<LemonEdge.API.Entities.IEntityPeriodClosing>().PeriodClosedDate))).Count() <= 0", "You can't close a period for an entity before an existing closed period.")]
DateTimeOffset PeriodClosedDate { get; set; }
Property Value
Type | Description |
---|---|
System.DateTimeOffset |