Created
February 22, 2018 23:38
-
-
Save dcomartin/c1634ee019133982e75877ed7f607cf2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@model AspNetCore.Demo.ShoppingCartViewModel | |
<h1>Shopping Cart</h1> | |
<div class="basket-content"> | |
@foreach (var item in Model.Products) | |
{ | |
<div class="basket-item"> | |
<div class="basket-item-product"> | |
<!-- IUrlHelper --> | |
<a href="@Url.Action("Product", "Products", new { item.Id })"> | |
@item.Product | |
</a> | |
<!-- Tag Helper --> | |
<a asp-controller="Products" asp-action="Action" | |
asp-route-id="@item.Id">@item.Product</a> | |
</div> | |
<div class="basket-item-colour">@item.Colour</div> | |
<div class="basket-item-size">@item.Size</div> | |
<div class="basket-item-price">@item.Price</div> | |
</div> | |
} | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment