@page
@model HouseModel
@{
    ViewData["Title"] = "House";
}
<h1>@ViewData["Title"]</h1>

<table class="table">
    <thead>
        <tr>
          <th>
                @Html.DisplayNameFor(model => model.Houses[0].Number)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Houses[0].Street)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Houses[0].City)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Houses[0].Country)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Houses[0].Postcode)
            </th>
            <th></th>
        </tr>
    </thead>
    <tbody>
@foreach (var item in Model.Houses) {
        <tr>
          <td>
                @Html.DisplayFor(modelItem => item.Number)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Street)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.City)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Country)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Postcode)
            </td>
            <td>
                <a asp-page="./DeleteHouse" id="delete" asp-route-id="@item.ID">Delete</a>
                <a asp-page="./EditHouse" id="boxlink1" asp-route-id="@item.ID">Edit</a> 
               
            </td>
        </tr>
}
    </tbody>
</table>
<br>
<a id="boxlink" class="boxlin2" asp-area="" asp-page="/AddHouse">ADD</a>