Ajout des boutons de Modération dans la page projet
This commit is contained in:
parent
7be3bac167
commit
0579eddf81
23 changed files with 281 additions and 226 deletions
|
|
@ -58,7 +58,7 @@
|
|||
<!-- Sidebar : informations du créateur -->
|
||||
<div class="col-lg-4">
|
||||
<div class="card text-center shadow-sm p-4">
|
||||
<a href="index.php?ctrl=user&action=user&id={$objProject->getUser()}" class="text-decoration-none text-dark">
|
||||
<a href="index.php?ctrl=user&action=user&id={$objProject->getUser_id()}" class="text-decoration-none text-dark">
|
||||
<img src="{$objProject->getUser_image()}"
|
||||
class="rounded-circle mb-3 mx-auto"
|
||||
style="width:100px;height:100px;object-fit:cover;">
|
||||
|
|
@ -67,13 +67,31 @@
|
|||
|
||||
<p class="text-muted small">
|
||||
Publié le {$objProject->getCreation_date()}
|
||||
|
||||
</p>
|
||||
|
||||
<button class="btn btn-primary">Contacter le talent</button>
|
||||
|
||||
</div>
|
||||
{*Controle de l'utilisateur ainsi que du status du projet + Suppression disponible pour l'utilisateur possédant le projet*}
|
||||
{if isset($smarty.session.user) and $smarty.session.user.user_status == 2 or $smarty.session.user.user_id == $objProject->getUser_id()}
|
||||
<div class="border rounded text-center">
|
||||
<a class="btn btn-sm m-1 btn-danger" href="?ctrl=project&action=delete&id={$objProject->getId()}" name="toDelete">Supprimer le projet</a>
|
||||
<a class="btn btn-sm m-1 btn-warning" href="?ctrl=project&action=addedit&id={$objProject->getId()}" name="toEdit">Modifier le projet</a>
|
||||
{/if}
|
||||
|
||||
{*Conditions permettant au Modérateur de modifier le status d'un projet*}
|
||||
{if isset($smarty.session.user) and $smarty.session.user.user_status == 2 and $objProject->getStatus() eq "en_attente"}
|
||||
<a class="btn btn-sm m-1 btn-success" href="?ctrl=project&action=accept&id={$objProject->getId()}" name="toPublished">Accepter</a>
|
||||
<a class="btn btn-sm m-1 btn-warning" href="?ctrl=project&action=refuse&id={$objProject->getId()}" name="toRefused">Refuser</a>
|
||||
</div>
|
||||
{elseif $projectStatus eq "refusé"}
|
||||
<p class="text-danger fw-bold">Portfolio refusé</p>
|
||||
{/if}
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</main>
|
||||
{/block}
|
||||
Loading…
Add table
Add a link
Reference in a new issue