mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-04-19 19:14:51 +00:00
36 lines
No EOL
1.1 KiB
Text
36 lines
No EOL
1.1 KiB
Text
@page "/photos/{pageNumber:int}"
|
|
@using LBPUnion.ProjectLighthouse.PlayerData
|
|
@using LBPUnion.ProjectLighthouse.Types
|
|
@model LBPUnion.ProjectLighthouse.Servers.Website.Pages.PhotosPage
|
|
|
|
@{
|
|
Layout = "Layouts/BaseLayout";
|
|
Model.Title = "Photos";
|
|
}
|
|
|
|
<p>There are @Model.PhotoCount total photos!</p>
|
|
|
|
<form action="/photos/0">
|
|
<div class="ui icon input">
|
|
<input type="text" name="name" placeholder="Search photos..." value="@Model.SearchValue">
|
|
<i class="search icon"></i>
|
|
</div>
|
|
</form>
|
|
<div class="ui divider"></div>
|
|
|
|
@foreach (Photo photo in Model.Photos)
|
|
{
|
|
<div class="ui segment">
|
|
@await Html.PartialAsync("Partials/PhotoPartial", photo)
|
|
</div>
|
|
}
|
|
|
|
@if (Model.PageNumber != 0)
|
|
{
|
|
<a href="/photos/@(Model.PageNumber - 1)@(Model.SearchValue?.Length == 0 ? "" : "?name=" + Model.SearchValue)">Previous Page</a>
|
|
}
|
|
@(Model.PageNumber + 1) / @(Model.PageAmount)
|
|
@if (Model.PageNumber < Model.PageAmount - 1)
|
|
{
|
|
<a href="/photos/@(Model.PageNumber + 1)@(Model.SearchValue?.Length == 0 ? "" : "?name=" + Model.SearchValue)">Next Page</a>
|
|
} |