Beispiel #1
0
        protected virtual IShipmentTypeStateCreated Map(ICreateShipmentType c)
        {
            var stateEventId            = new ShipmentTypeEventId(c.ShipmentTypeId, c.Version);
            IShipmentTypeStateCreated e = NewShipmentTypeStateCreated(stateEventId);

            e.ParentTypeId = c.ParentTypeId;
            e.HasTable     = c.HasTable;
            e.Description  = c.Description;
            e.Active       = c.Active;
            e.CommandId    = c.CommandId;


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


            return(e);
        }
Beispiel #2
0
 public virtual void When(ICreateShipmentType c)
 {
     Update(c, ar => ar.Create(c));
 }
Beispiel #3
0
        public virtual void Create(ICreateShipmentType c)
        {
            IShipmentTypeStateCreated e = Map(c);

            Apply(e);
        }
 void IShipmentTypeApplicationService.When(ICreateShipmentType c)
 {
     this.When((CreateShipmentTypeDto)c);
 }