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); }
public virtual void When(ICreateShipmentType c) { Update(c, ar => ar.Create(c)); }
public virtual void Create(ICreateShipmentType c) { IShipmentTypeStateCreated e = Map(c); Apply(e); }
void IShipmentTypeApplicationService.When(ICreateShipmentType c) { this.When((CreateShipmentTypeDto)c); }