Guest User

Untitled

a guest
Oct 2nd, 2019
78
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @model SimpleGallery.Helpers.PagedData<ImageModel>
  2.  
  3. <div class="container body-content">
  4.     <div class="row">
  5.         @foreach (var image in Model.Data)
  6.         {
  7.             <a asp-controller="Gallery" asp-action="Detail" asp-route-id="@image.Id">
  8.                 <div class="gallery-image" style="background-image:url(@image.Url)"></div>
  9.             </a>
  10.         }
  11.     </div>
  12.     <div class="row">
  13.         @for (int i = 1; i <= Model.NumberOfPages; i++)
  14.        {
  15.            if (i == Model.CurrentPage)
  16.            {
  17.                @i
  18.            }
  19.            else
  20.            {
  21.                <a class="page-number" href="javascript:void();">@i</a>
  22.             }
  23.         }
  24.     </div>
  25. </div>
RAW Paste Data