7.6.3 Creating a Partial View; Listing 7-29 Using a Partial View in the List.cshtml File
parent
bc939b22da
commit
5b843e3cdb
|
@ -7,15 +7,9 @@
|
|||
|
||||
@foreach (var p in Model.Products)
|
||||
{
|
||||
<div class="well">
|
||||
<h3>
|
||||
<strong>@p.Name</strong>
|
||||
<span class="pull-right label label-primary">@p.Price.ToString("c")</span>
|
||||
</h3>
|
||||
<span class="lead">@p.Description</span>
|
||||
</div>
|
||||
@Html.Partial("ProductSummary", p)
|
||||
}
|
||||
|
||||
<div>
|
||||
<div class="pager">
|
||||
@Html.PageLinks(Model.PagingInfo, x => Url.Action("List", new { page = x}))
|
||||
</div>
|
Loading…
Reference in New Issue