Пример #1
0
        private CartDetailItemModel CreateCartDetailItemModel(MOrder_OrderItem from)
        {
            var to = new CartDetailItemModel();

            Copy(to, from);
            return(to);
        }
Пример #2
0
        private void Copy(CartDetailItemModel to, MOrder_OrderItem from)
        {
            to.OrderableReference = from.OrderableReference;
            to.OrderItemId        = from.OrderItemId;
            to.Name       = from.Description;
            to.Sku        = from.Sku;
            to.Quantity   = from.NetQuantity;
            to.KitPrice   = from.UnitPrice;
            to.TotalPrice = from.TotalPrice;

            to.Components = CreateCartItemComponentModels(from.OrderItemComponents);
        }