Merge pull request 'Mis a jour de la prod' (#220) from dev into main
Reviewed-on: https://10.4.0.131/gitea/DI1-P4-E1/Webzine/pulls/220
This commit is contained in:
@@ -436,6 +436,7 @@ public class DbTitreRepository : ITitreRepository
|
||||
return this.context.Titres
|
||||
.AsNoTracking()
|
||||
.OrderByDescending(t => t.DateCreation)
|
||||
.ThenByDescending(t => t.IdTitre)
|
||||
.Paginate(offset, limit)
|
||||
.Include(t => t.Artiste)
|
||||
.Include(a => a.Styles);
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
@using Webzine.Business.Contracts.Dto
|
||||
@model DashboardDTO
|
||||
@{
|
||||
ViewData["Title"] = "Dashboard";
|
||||
}
|
||||
|
||||
<h1 class="mb-4">Tableau de bord</h1>
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@ namespace Webzine.WebApplication.Controllers
|
||||
/// <param name="style">Nom du style musical.</param>
|
||||
/// <param name="page">Numéro de la page.</param>
|
||||
/// <returns>Vue contenant la liste filtree.</returns>
|
||||
[Route("/titres/styles/{style}", Name = "TitresParStyle")]
|
||||
[Route("/titres/style/{style}", Name = "TitresParStyle")]
|
||||
public IActionResult Style(string style, int page = 0)
|
||||
{
|
||||
var offset = page * 10;
|
||||
|
||||
@@ -73,21 +73,34 @@
|
||||
</div>
|
||||
}
|
||||
<!-- Bouton -->
|
||||
<div class="row justify-content-between">
|
||||
<div class="d-flex align-items-center justify-content-between mt-3">
|
||||
@if (Model.Page > 0)
|
||||
{
|
||||
<a asp-action="Index" asp-route-page="@(Model.Page - 1)"
|
||||
class="btn btn-secondary col-auto mt-3">
|
||||
class="btn btn-secondary">
|
||||
<< Titre plus récent
|
||||
</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div></div>
|
||||
}
|
||||
|
||||
<p class="mb-0">
|
||||
Page : @(Model.Page + 1) sur @Model.TotalPages
|
||||
</p>
|
||||
|
||||
@if (Model.Page < Model.TotalPages - 1)
|
||||
{
|
||||
<a asp-action="Index" asp-route-page="@(Model.Page + 1)"
|
||||
class="btn btn-secondary col-auto mt-3 ms-auto">
|
||||
class="btn btn-secondary">
|
||||
Titre plus anciens >>
|
||||
</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div></div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<div class="container-fluid">
|
||||
|
||||
<!-- Logo -->
|
||||
<a class="navbar-brand" href="#">Webzine</a>
|
||||
<a class="navbar-brand" asp-area="" asp-controller="Accueil" asp-action="Index">Webzine</a>
|
||||
|
||||
<!-- bouton mobile -->
|
||||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarWebzine">
|
||||
|
||||
Reference in New Issue
Block a user