2017-09-13 23:50:36 +09:00
|
|
|
@model StoresViewModel
|
|
|
|
@{
|
2017-10-27 17:53:04 +09:00
|
|
|
ViewData["Title"] = "Stores";
|
2017-09-13 23:50:36 +09:00
|
|
|
}
|
|
|
|
|
|
|
|
<section>
|
2017-10-27 17:53:04 +09:00
|
|
|
<div class="container">
|
2019-06-06 18:47:31 +09:00
|
|
|
@if (TempData.ContainsKey("TempDataProperty-StatusMessage"))
|
|
|
|
{
|
2017-10-27 17:53:04 +09:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-lg-12 text-center">
|
2018-05-08 17:57:53 +09:00
|
|
|
<partial name="_StatusMessage" for="@TempData["TempDataProperty-StatusMessage"]" />
|
2017-10-27 17:53:04 +09:00
|
|
|
</div>
|
|
|
|
</div>
|
2019-06-06 18:47:31 +09:00
|
|
|
}
|
2017-10-27 17:53:04 +09:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-lg-12 text-center">
|
|
|
|
<h2 class="section-heading">@ViewData["Title"]</h2>
|
|
|
|
<hr class="primary">
|
|
|
|
<p>Create and manage store settings.</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
2017-09-13 23:50:36 +09:00
|
|
|
|
2017-10-27 17:53:04 +09:00
|
|
|
<div class="row">
|
2019-05-12 02:13:26 -06:00
|
|
|
<a asp-action="CreateStore" class="btn btn-primary" role="button" id="CreateStore"><span class="fa fa-plus"></span> Create a new store</a>
|
2018-04-08 00:06:47 -05:00
|
|
|
<table class="table table-sm table-responsive-md">
|
2018-04-05 23:20:12 -05:00
|
|
|
<thead>
|
2017-10-27 17:53:04 +09:00
|
|
|
<tr>
|
|
|
|
<th>Name</th>
|
|
|
|
<th>Website</th>
|
2018-03-21 02:48:11 +09:00
|
|
|
<th style="text-align:right">Actions</th>
|
2017-10-27 17:53:04 +09:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
2018-04-05 23:20:12 -05:00
|
|
|
@foreach (var store in Model.Stores)
|
2017-10-27 17:53:04 +09:00
|
|
|
{
|
|
|
|
<tr>
|
|
|
|
<td>@store.Name</td>
|
|
|
|
<td>
|
2018-04-05 23:20:12 -05:00
|
|
|
@if (!string.IsNullOrEmpty(store.WebSite))
|
2017-10-27 17:53:04 +09:00
|
|
|
{
|
|
|
|
<a href="@store.WebSite">@store.WebSite</a>
|
|
|
|
}
|
|
|
|
</td>
|
2018-03-23 16:24:57 +09:00
|
|
|
<td style="text-align:right">
|
2018-10-29 12:44:20 +09:00
|
|
|
<a asp-action="ListInvoices" asp-controller="Invoice" asp-route-searchTerm="storeid:@store.Id">Invoices</a><span> - </span>
|
2018-04-05 23:20:12 -05:00
|
|
|
@if (store.IsOwner)
|
2018-03-23 16:24:57 +09:00
|
|
|
{
|
|
|
|
<a asp-action="UpdateStore" asp-controller="Stores" asp-route-storeId="@store.Id">Settings</a><span> - </span>
|
|
|
|
}
|
|
|
|
<a asp-action="DeleteStore" asp-route-storeId="@store.Id">Remove</a>
|
|
|
|
</td>
|
2017-10-27 17:53:04 +09:00
|
|
|
</tr>
|
|
|
|
}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
2017-09-13 23:50:36 +09:00
|
|
|
|
2017-10-27 17:53:04 +09:00
|
|
|
</div>
|
|
|
|
</section>
|