private PhysicalInventoryLineEventId NewPhysicalInventoryLineEventId(InventoryItemId inventoryItemId) { var eId = new PhysicalInventoryLineEventId(); eId.PhysicalInventoryDocumentNumber = this.PhysicalInventoryEventId.DocumentNumber; eId.InventoryItemId = inventoryItemId; eId.PhysicalInventoryVersion = this.PhysicalInventoryEventId.Version; return(eId); }
}// END Map(IMergePatch... //////////////////////////// protected virtual IPhysicalInventoryLineStateRemoved MapRemove(IRemovePhysicalInventoryLine c, IPhysicalInventoryCommand outerCommand, long version) { c.RequesterId = outerCommand.RequesterId; var stateEventId = new PhysicalInventoryLineEventId(c.PhysicalInventoryDocumentNumber, c.InventoryItemId, version); IPhysicalInventoryLineStateRemoved e = NewPhysicalInventoryLineStateRemoved(stateEventId); e.CreatedBy = (string)c.RequesterId; e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>(); return(e); }// END Map(IRemove... ////////////////////////////
protected virtual IPhysicalInventoryLineStateCreated MapCreate(ICreatePhysicalInventoryLine c, IPhysicalInventoryCommand outerCommand, long version, IPhysicalInventoryState outerState) { c.RequesterId = outerCommand.RequesterId; var stateEventId = new PhysicalInventoryLineEventId(c.PhysicalInventoryDocumentNumber, c.InventoryItemId, version); IPhysicalInventoryLineStateCreated e = NewPhysicalInventoryLineStateCreated(stateEventId); var s = outerState.PhysicalInventoryLines.Get(c.InventoryItemId, true); e.BookQuantity = c.BookQuantity; e.CountedQuantity = c.CountedQuantity; e.Processed = c.Processed; e.LineNumber = c.LineNumber; e.ReversalLineNumber = c.ReversalLineNumber; e.Description = c.Description; e.CreatedBy = (string)c.RequesterId; e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>(); return(e); }// END Map(ICreate... ////////////////////////////
public override bool Equals(object obj) { if (Object.ReferenceEquals(this, obj)) { return(true); } PhysicalInventoryLineEventId other = obj as PhysicalInventoryLineEventId; if (other == null) { return(false); } return(true && Object.Equals(this.PhysicalInventoryDocumentNumber, other.PhysicalInventoryDocumentNumber) && Object.Equals(this.InventoryItemId, other.InventoryItemId) && Object.Equals(this.PhysicalInventoryVersion, other.PhysicalInventoryVersion) ); }
protected PhysicalInventoryLineEventBase(PhysicalInventoryLineEventId stateEventId) { this.PhysicalInventoryLineEventId = stateEventId; }
public PhysicalInventoryLineStateRemoved(PhysicalInventoryLineEventId stateEventId) : base(stateEventId) { }
public PhysicalInventoryLineStateMergePatched(PhysicalInventoryLineEventId stateEventId) : base(stateEventId) { }
protected PhysicalInventoryLineStateEventBase(PhysicalInventoryLineEventId stateEventId) : base(stateEventId) { }
private PhysicalInventoryLineStateRemoved NewPhysicalInventoryLineStateRemoved(PhysicalInventoryLineEventId stateEventId) { return(new PhysicalInventoryLineStateRemoved(stateEventId)); }
private PhysicalInventoryLineStateMergePatched NewPhysicalInventoryLineStateMergePatched(PhysicalInventoryLineEventId stateEventId) { return(new PhysicalInventoryLineStateMergePatched(stateEventId)); }
protected PhysicalInventoryLineEventId NewPhysicalInventoryLineEventId(InventoryItemId inventoryItemId) { var stateEventId = new PhysicalInventoryLineEventId(this.PhysicalInventoryEventId.DocumentNumber, inventoryItemId, this.PhysicalInventoryEventId.Version); return(stateEventId); }