protected virtual IOrderItemMvoStateCreated Map(ICreateOrderItemMvo c) { var stateEventId = new OrderItemMvoEventId(c.OrderItemId, c.OrderVersion); IOrderItemMvoStateCreated e = NewOrderItemMvoStateCreated(stateEventId); e.ProductId = c.ProductId; e.ExternalProductId = c.ExternalProductId; e.Quantity = c.Quantity; e.CancelQuantity = c.CancelQuantity; e.SelectedAmount = c.SelectedAmount; e.ExternalId = c.ExternalId; e.OrderItemTypeId = c.OrderItemTypeId; e.OrderItemGroupSeqId = c.OrderItemGroupSeqId; e.IsItemGroupPrimary = c.IsItemGroupPrimary; e.FromInventoryItemId = c.FromInventoryItemId; e.IsPromo = c.IsPromo; e.QuoteId = c.QuoteId; e.QuoteItemSeqId = c.QuoteItemSeqId; e.ShoppingListId = c.ShoppingListId; e.ShoppingListItemSeqId = c.ShoppingListItemSeqId; e.UnitPrice = c.UnitPrice; e.UnitListPrice = c.UnitListPrice; e.UnitAverageCost = c.UnitAverageCost; e.UnitRecurringPrice = c.UnitRecurringPrice; e.IsModifiedPrice = c.IsModifiedPrice; e.RecurringFreqUomId = c.RecurringFreqUomId; e.ItemDescription = c.ItemDescription; e.Comments = c.Comments; e.CorrespondingPoId = c.CorrespondingPoId; e.StatusId = c.StatusId; e.SyncStatusId = c.SyncStatusId; e.EstimatedShipDate = c.EstimatedShipDate; e.EstimatedDeliveryDate = c.EstimatedDeliveryDate; e.AutoCancelDate = c.AutoCancelDate; e.DontCancelSetDate = c.DontCancelSetDate; e.DontCancelSetBy = c.DontCancelSetBy; e.ShipBeforeDate = c.ShipBeforeDate; e.ShipAfterDate = c.ShipAfterDate; e.CancelBackOrderDate = c.CancelBackOrderDate; e.OverrideGlAccountId = c.OverrideGlAccountId; e.Version = c.Version; e.Active = c.Active; e.OrderOrderTypeId = c.OrderOrderTypeId; e.OrderOrderName = c.OrderOrderName; e.OrderExternalId = c.OrderExternalId; e.OrderSalesChannelEnumId = c.OrderSalesChannelEnumId; e.OrderOrderDate = c.OrderOrderDate; e.OrderPriority = c.OrderPriority; e.OrderEntryDate = c.OrderEntryDate; e.OrderPickSheetPrintedDate = c.OrderPickSheetPrintedDate; e.OrderStatusId = c.OrderStatusId; e.OrderCurrencyUom = c.OrderCurrencyUom; e.OrderSyncStatusId = c.OrderSyncStatusId; e.OrderBillingAccountId = c.OrderBillingAccountId; e.OrderOriginFacilityId = c.OrderOriginFacilityId; e.OrderWebSiteId = c.OrderWebSiteId; e.OrderProductStoreId = c.OrderProductStoreId; e.OrderTerminalId = c.OrderTerminalId; e.OrderTransactionId = c.OrderTransactionId; e.OrderAutoOrderShoppingListId = c.OrderAutoOrderShoppingListId; e.OrderNeedsInventoryIssuance = c.OrderNeedsInventoryIssuance; e.OrderIsRushOrder = c.OrderIsRushOrder; e.OrderInternalCode = c.OrderInternalCode; e.OrderRemainingSubTotal = c.OrderRemainingSubTotal; e.OrderGrandTotal = c.OrderGrandTotal; e.OrderInvoicePerShipment = c.OrderInvoicePerShipment; e.OrderCreatedBy = c.OrderCreatedBy; e.OrderCreatedAt = c.OrderCreatedAt; e.OrderUpdatedBy = c.OrderUpdatedBy; e.OrderUpdatedAt = c.OrderUpdatedAt; e.OrderActive = c.OrderActive; e.CommandId = c.CommandId; e.CreatedBy = (string)c.RequesterId; e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>(); var orderVersion = c.OrderVersion; return(e); }
void IOrderItemMvoApplicationService.When(ICreateOrderItemMvo c) { this.When((CreateOrderItemMvoDto)c); }
public virtual void Create(ICreateOrderItemMvo c) { IOrderItemMvoStateCreated e = Map(c); Apply(e); }
public virtual void When(ICreateOrderItemMvo c) { Update(c, ar => ar.Create(c)); }