예제 #1
0
        protected virtual ILotStateMergePatched Map(IMergePatchLot c)
        {
            var stateEventId        = new LotEventId(c.LotId, c.Version);
            ILotStateMergePatched e = NewLotStateMergePatched(stateEventId);

            e.Quantity                        = c.Quantity;
            e.ExpirationDate                  = c.ExpirationDate;
            e.Active                          = c.Active;
            e.IsPropertyQuantityRemoved       = c.IsPropertyQuantityRemoved;
            e.IsPropertyExpirationDateRemoved = c.IsPropertyExpirationDateRemoved;
            e.IsPropertyActiveRemoved         = c.IsPropertyActiveRemoved;

            e.CommandId = c.CommandId;


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

            var version = c.Version;


            return(e);
        }
예제 #2
0
 void ILotApplicationService.When(IMergePatchLot c)
 {
     this.When((MergePatchLotDto)c);
 }
예제 #3
0
        public virtual void MergePatch(IMergePatchLot c)
        {
            ILotStateMergePatched e = Map(c);

            Apply(e);
        }
예제 #4
0
 public virtual void When(IMergePatchLot c)
 {
     Update(c, ar => ar.MergePatch(c));
 }