Add index and create

This commit is contained in:
2014-05-20 14:24:08 -04:00
parent ef88c52658
commit 0fcfa3a3a1
8 changed files with 159 additions and 22 deletions
+25
View File
@@ -0,0 +1,25 @@
@model Dictionary<string,List<string>>
@{
ViewBag.Title = "Cities by County";
}
@Html.Partial("_StatusMessage")
<h2>@ViewBag.Title</h2>
<div>
@foreach (var countyCities in Model)
{
<div>
<h3>@countyCities.Key</h3>
@foreach (var city in countyCities.Value)
{
<span class="label">
@city
</span>
}
@Html.ActionLink("Add New City", "Create", new {County=countyCities.Key}, new { @class = "btn" })
</div>
}
</div>