Ejemplo n.º 1
0
        public virtual void When(IMovementConfirmationLineStateRemoved e)
        {
            ThrowOnWrongEvent(e);

            this.Deleted   = true;
            this.UpdatedBy = e.CreatedBy;
            this.UpdatedAt = e.CreatedAt;
        }
Ejemplo n.º 2
0
        }// END Map(IMergePatch... ////////////////////////////

        protected virtual IMovementConfirmationLineStateRemoved MapRemove(IRemoveMovementConfirmationLine c, IMovementConfirmationCommand outerCommand, long version)
        {
            c.RequesterId = outerCommand.RequesterId;
            var stateEventId = new MovementConfirmationLineEventId(c.MovementConfirmationDocumentNumber, c.LineNumber, version);
            IMovementConfirmationLineStateRemoved e = NewMovementConfirmationLineStateRemoved(stateEventId);


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>();

            return(e);
        }// END Map(IRemove... ////////////////////////////
Ejemplo n.º 3
0
 public virtual void AddMovementConfirmationLineEvent(IMovementConfirmationLineStateRemoved e)
 {
     ThrowOnInconsistentEventIds(e);
     this._movementConfirmationLineEvents[e.MovementConfirmationLineEventId] = e;
 }
        public virtual MovementConfirmationLineStateRemovedDto ToMovementConfirmationLineStateRemovedDto(IMovementConfirmationLineStateRemoved e)
        {
            var dto = new MovementConfirmationLineStateRemovedDto();

            dto.MovementConfirmationLineEventId = e.MovementConfirmationLineEventId;
            dto.CreatedAt = e.CreatedAt;
            dto.CreatedBy = e.CreatedBy;
            dto.Version   = e.Version;
            dto.CommandId = e.CommandId;

            return(dto);
        }
Ejemplo n.º 5
0
 void IMovementConfirmationLineState.When(IMovementConfirmationLineStateRemoved e)
 {
     throw new NotSupportedException();
 }
 void IMovementConfirmationStateDeleted.AddMovementConfirmationLineEvent(IMovementConfirmationLineStateRemoved e)
 {
     this._movementConfirmationLineEvents.AddMovementConfirmationLineEvent(e);
 }
 public void AddMovementConfirmationLineEvent(IMovementConfirmationLineStateRemoved e)
 {
     _innerStateEvents.Add((MovementConfirmationLineStateRemovedDto)e);
 }