protected virtual IUomConversionStateCreated Map(ICreateUomConversion c) { var stateEventId = new UomConversionEventId(c.UomConversionId, c.Version); IUomConversionStateCreated e = NewUomConversionStateCreated(stateEventId); e.ConversionFactor = c.ConversionFactor; e.CustomMethodId = c.CustomMethodId; e.DecimalScale = c.DecimalScale; e.RoundingMode = c.RoundingMode; 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); }
void IUomConversionApplicationService.When(ICreateUomConversion c) { this.When((CreateUomConversionDto)c); }
public virtual void Create(ICreateUomConversion c) { IUomConversionStateCreated e = Map(c); Apply(e); }
public virtual void When(ICreateUomConversion c) { Update(c, ar => ar.Create(c)); }