75 lines
3.2 KiB
Plaintext
75 lines
3.2 KiB
Plaintext
|
|
@page
|
||
|
|
@model JobsMedical.Web.Pages.Admin.FacilitiesModel
|
||
|
|
@{
|
||
|
|
ViewData["Title"] = "مدیریت مراکز درمانی";
|
||
|
|
string TypeLabel(FacilityType t) => t switch
|
||
|
|
{
|
||
|
|
FacilityType.Hospital => "بیمارستان",
|
||
|
|
FacilityType.Clinic => "کلینیک",
|
||
|
|
_ => "درمانگاه",
|
||
|
|
};
|
||
|
|
}
|
||
|
|
|
||
|
|
<div class="page-head">
|
||
|
|
<div class="container">
|
||
|
|
<h1>تأیید مراکز درمانی</h1>
|
||
|
|
<p class="muted">
|
||
|
|
<a asp-page="/Admin/Index">← صف آگهیها</a>
|
||
|
|
· @JalaliDate.ToPersianDigits(Model.Pending.Count.ToString()) مرکز در انتظار تأیید
|
||
|
|
</p>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
|
||
|
|
<div class="container section">
|
||
|
|
<h2 style="font-size:20px;">در انتظار تأیید</h2>
|
||
|
|
@if (Model.Pending.Count == 0)
|
||
|
|
{
|
||
|
|
<div class="card empty-state">مرکزی در انتظار تأیید نیست.</div>
|
||
|
|
}
|
||
|
|
else
|
||
|
|
{
|
||
|
|
foreach (var f in Model.Pending)
|
||
|
|
{
|
||
|
|
<div class="card card-pad" style="margin-bottom:10px;">
|
||
|
|
<div class="row" style="display:flex; justify-content:space-between; align-items:center; gap:10px;">
|
||
|
|
<div>
|
||
|
|
<strong>@f.Name</strong> — @TypeLabel(f.Type)
|
||
|
|
<div class="muted" style="font-size:13px;">
|
||
|
|
📍 @f.City?.Name@(f.District is not null ? "، " + f.District.Name : "")
|
||
|
|
@if (f.OwnerUser is not null) { <text> · مالک: <span dir="ltr">@JalaliDate.ToPersianDigits(f.OwnerUser.Phone)</span></text> }
|
||
|
|
@if (!string.IsNullOrEmpty(f.Phone)) { <text> · تلفن: <span dir="ltr">@JalaliDate.ToPersianDigits(f.Phone)</span></text> }
|
||
|
|
</div>
|
||
|
|
@if (!string.IsNullOrEmpty(f.Address)) { <div class="muted" style="font-size:13px;">@f.Address</div> }
|
||
|
|
</div>
|
||
|
|
<form method="post">
|
||
|
|
<button asp-page-handler="Verify" asp-route-id="@f.Id" class="btn btn-accent" style="white-space:nowrap;">✓ تأیید</button>
|
||
|
|
</form>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
<h2 style="font-size:20px; margin-top:30px;">مراکز تأییدشده</h2>
|
||
|
|
@if (Model.Verified.Count == 0)
|
||
|
|
{
|
||
|
|
<div class="card empty-state">هنوز مرکزی تأیید نشده.</div>
|
||
|
|
}
|
||
|
|
else
|
||
|
|
{
|
||
|
|
foreach (var f in Model.Verified)
|
||
|
|
{
|
||
|
|
<div class="card card-pad" style="margin-bottom:10px;">
|
||
|
|
<div class="row" style="display:flex; justify-content:space-between; align-items:center; gap:10px;">
|
||
|
|
<div>
|
||
|
|
<strong>@f.Name</strong> <span class="badge badge-verified">✓ تأیید شده</span>
|
||
|
|
<div class="muted" style="font-size:13px;">📍 @f.City?.Name — @TypeLabel(f.Type)</div>
|
||
|
|
</div>
|
||
|
|
<form method="post">
|
||
|
|
<button asp-page-handler="Unverify" asp-route-id="@f.Id" class="btn btn-outline" style="white-space:nowrap;">لغو تأیید</button>
|
||
|
|
</form>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
}
|
||
|
|
}
|
||
|
|
</div>
|