@model CartWise.Web.ViewModels.Household.HouseholdIndexViewModel
@{
    ViewData["Title"] = Model.Name;
}

<h1>@Model.Name</h1>
<p class="text-muted">Created @Model.CreatedUtc.ToLocalTime().ToString("MMMM d, yyyy")</p>

<h2>Members</h2>
<table class="table">
    <thead>
        <tr>
            <th scope="col">Name</th>
            <th scope="col">Role</th>
            <th scope="col">Joined</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var member in Model.Members)
        {
            <tr>
                <td>@member.DisplayName</td>
                <td>@member.Role</td>
                <td>@member.JoinedUtc.ToLocalTime().ToString("MMMM d, yyyy")</td>
            </tr>
        }
    </tbody>
</table>
