public ActionResult Shop() { ViewBag.Message = "Your shopping page."; _ItemsController itemsController = new _ItemsController(); List <Item> items = itemsController.FetchAllItems(); return(View(items)); }
public static Cart Create(int cartId) { _ItemsController itemsController = new _ItemsController(); CartItemsController cartItemsController = new CartItemsController(); User user = new UserBuilder() .SetFirstName("August") .SetLastName("Alexandersson") .SetAge(21) .SetTitle("Dr") .SetBillingAddress("SandlyckevÀgen 28") .SetCountry("Sweden") .SetCity("BorÄs") .SetEmail("*****@*****.**") .SetId(0) .Build(); List <PickedItem> items = itemsController .GetItemsFromCartItems( cartItemsController.GetListOfItems(cartId) ); return(new Cart(cartId, items, user)); }