gehgassi_backend/gehGassi.Web/Views/AppUserReport/_ShowDogOwnerProfile.cshtml

86 lines
3.2 KiB
Plaintext

@*
For more information on enabling MVC for empty projects, visit http://go.microsoft.com/fwlink/?LinkID=397860
*@
@using Microsoft.AspNetCore.Mvc.Localization
@using gehGassi.Web.Models
@using Microsoft.Extensions.Localization
@using gehGassi.Web.Helper
@using gehGassi.Core.Services
@model gehGassi.Web.Models.AppUserVm
@inject IViewLocalizer Localizer
@inject ICountryService CountryService
@{
IStringLocalizer annotationsLocalizer = ViewBag.AnnotationsLocalizer;
List<DogVm> dogs = new List<DogVm>();
if (ViewBag.Dogs != null)
{
dogs = ViewBag.Dogs as List<DogVm>;
}
}
<section id="appUserReportShowDogOwnerProfileContainer">
<div class="form">
<div id="pageTitleAdd" style="display: none;">@ViewData["Title"]</div>
<div class="row mb-2">
<div class="col-sm-2">
<div>
@if (!string.IsNullOrWhiteSpace(Model.Photo))
{
<img src="/file/documents/@Model.Photo" class="img-user-verybig" alt="" />
}
else
{
<img src="/images/icon_user.png" class="img-user-verybig" alt="" />
}
</div>
</div>
<div class="col-sm-10">
<h3>@Model.FirstName @Model.LastName</h3>
<div>@annotationsLocalizer["AppUser_Type"]: <strong>@Model.Type.GetDisplayName(annotationsLocalizer)</strong></div>
<div>@Model.Address.AddressLine1</div>
<div>@Model.Address.AddressLine2</div>
<div>@Model.Address.Zip, @Model.Address.City</div>
<div>@CountryService.GetState(Model.Address.CountryCode, Model.Address.State).Name, @CountryService.GetCountry(Model.Address.CountryCode).Name</div>
</div>
</div>
<div class="h3 mb-3">@Localizer["Common_Dogs"]</div>
<div class="row mb-2">
@foreach (var dog in dogs)
{
<div class="col-sm-4 p-2 m-2" style="border: 1px solid #eeeeee;">
<div class="row mb-2">
<div class="col-sm-4">
@if (!string.IsNullOrWhiteSpace(dog.Photo))
{
<img src="/file/documents/@dog.Photo" class="img-user-big" alt="" />
}
else
{
<img src="/images/icon_dog.png.png" class="img-user-big" alt="" />
}
</div>
<div class="col-sm-8">
<h3>@dog.Name</h3>
</div>
</div>
</div>
}
</div>
<div class="row button-row">
<div class="col-12">
<div class="">
<button type="button" id="btnClose" class="btn btn-primary">@Localizer["Button_Close"]</button>
</div>
</div>
</div>
</div>
<system-js url="~/scripts/Views/AppUserReport/showDogOwnerProfile.js" fresh-import="true"></system-js>
</section>