Merge pull request #15 from Yasder5/guillaume
Fonctionnalité Modération sous Smarty + Débug
This commit is contained in:
commit
6eb58674be
13 changed files with 1046 additions and 22 deletions
|
|
@ -263,4 +263,46 @@
|
||||||
header("Location: index.php?ctrl=project&action=home");
|
header("Location: index.php?ctrl=project&action=home");
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function accept(){
|
||||||
|
|
||||||
|
//Récupéré l'id dans l'url
|
||||||
|
$intId = $_GET['id'];
|
||||||
|
|
||||||
|
//Je créer un nouveau model pour exec la commande SQL
|
||||||
|
$objProjectModel = new ProjectModel;
|
||||||
|
$objProjectModel->accept($intId);
|
||||||
|
|
||||||
|
//Redirection vers la page
|
||||||
|
header("Location: index.php");
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function refuse(){
|
||||||
|
|
||||||
|
//Récupéré l'id dans l'url
|
||||||
|
$intId = $_GET['id'];
|
||||||
|
|
||||||
|
//Je créer un nouveau model pour exec la commande SQL
|
||||||
|
$objProjectModel = new ProjectModel;
|
||||||
|
$objProjectModel->refuse($intId);
|
||||||
|
|
||||||
|
//Redirection vers la page
|
||||||
|
header("Location: index.php");
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function delete(){
|
||||||
|
|
||||||
|
//Récupéré l'id dans l'url
|
||||||
|
$intId = $_GET['id'];
|
||||||
|
|
||||||
|
//Je créer un nouveau model pour exec la commande SQL
|
||||||
|
$objProjectModel = new ProjectModel;
|
||||||
|
$objProjectModel->delete($intId);
|
||||||
|
|
||||||
|
//Redirection vers la page
|
||||||
|
header("Location: index.php");
|
||||||
|
exit;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -147,7 +147,4 @@ class UserCtrl extends MotherCtrl {
|
||||||
// Affichage de la vue inscription
|
// Affichage de la vue inscription
|
||||||
$this->_display("inscription");
|
$this->_display("inscription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -20,4 +20,16 @@
|
||||||
echo "Échec : " . $e->getMessage();
|
echo "Échec : " . $e->getMessage();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
Pour passer sur le serveur de YASS:
|
||||||
|
*"mysql:host=boulayoune.com;dbname=projet_folliow", // Serveur et BDD
|
||||||
|
"projet_user", //Nom d'utilisateur de la base de données
|
||||||
|
"F0lliowRules!",// Mot de passe de la base de données
|
||||||
|
|
||||||
|
Pour passer en local:
|
||||||
|
"mysql:host=localhost;dbname=projet_folliow", // Serveur et BDD
|
||||||
|
"root", //Nom d'utilisateur de la base de données
|
||||||
|
"",// Mot de passe de la base de données
|
||||||
|
*/
|
||||||
|
|
@ -122,4 +122,32 @@
|
||||||
|
|
||||||
return $rqPrep->fetch();
|
return $rqPrep->fetch();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function accept(int $id){
|
||||||
|
|
||||||
|
//SQL pour changer le status en accept
|
||||||
|
$strRq = "UPDATE project
|
||||||
|
SET project_status= 'publié'
|
||||||
|
WHERE project_id =".$id;
|
||||||
|
|
||||||
|
//retourne la commande
|
||||||
|
return $this->_db->query($strRq);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function refuse(int $id){
|
||||||
|
|
||||||
|
$strRq = "UPDATE project
|
||||||
|
SET project_status= 'refusé'
|
||||||
|
WHERE project_id =".$id;
|
||||||
|
|
||||||
|
return $this->_db->query($strRq);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function delete(int $id){
|
||||||
|
|
||||||
|
$strRq = "DELETE FROM project
|
||||||
|
WHERE project_id =".$id;
|
||||||
|
|
||||||
|
return $this->_db->query($strRq);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -0,0 +1,128 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 13:47:56
|
||||||
|
from 'file:views/projet_display.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989e58c411304_60305191',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'061ec8f4caa90f6cac9dd0d1f101149077158460' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/projet_display.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989e58c411304_60305191 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
$_smarty_tpl->getInheritance()->init($_smarty_tpl, true);
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$_smarty_tpl->getInheritance()->instanceBlock($_smarty_tpl, 'Block_13978244256989e58c406518_61332798', "content");
|
||||||
|
$_smarty_tpl->getInheritance()->endChild($_smarty_tpl, "views/layout.tpl", $_smarty_current_dir);
|
||||||
|
}
|
||||||
|
/* {block "content"} */
|
||||||
|
class Block_13978244256989e58c406518_61332798 extends \Smarty\Runtime\Block
|
||||||
|
{
|
||||||
|
public function callBlock(\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
?>
|
||||||
|
|
||||||
|
<main class="container mt-5 py-5">
|
||||||
|
|
||||||
|
<!-- Message après l'envoi d'email -->
|
||||||
|
<?php if ((true && (true && null !== ($_GET['mail'] ?? null))) && $_GET['mail'] === 'ok') {?>
|
||||||
|
<div class="alert alert-success">Email envoyé avec succès.</div>
|
||||||
|
<?php } elseif ((true && (true && null !== ($_GET['mail'] ?? null))) && $_GET['mail'] === 'fail') {?>
|
||||||
|
<div class="alert alert-danger">Erreur lors de l'envoi de l'email.</div>
|
||||||
|
<?php }?>
|
||||||
|
|
||||||
|
<div class="row g-4">
|
||||||
|
|
||||||
|
<!-- Contenu principal du projet -->
|
||||||
|
<div class="col-lg-8">
|
||||||
|
|
||||||
|
<h1 class="fw-bold"><?php echo $_smarty_tpl->getValue('objProject')->getTitle();?>
|
||||||
|
</h1>
|
||||||
|
|
||||||
|
<p class="text-muted">
|
||||||
|
<?php echo $_smarty_tpl->getValue('arrProject')['category_name'] ?? 'Général';?>
|
||||||
|
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<div class="mb-4 shadow-sm">
|
||||||
|
<img src=".<?php echo $_smarty_tpl->getValue('objProject')->getThumbnail();?>
|
||||||
|
"
|
||||||
|
class="img-fluid rounded w-100">
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="bg-light p-4 rounded mb-4">
|
||||||
|
<h4 class="border-bottom pb-2">Description</h4>
|
||||||
|
<p class="lead"><?php echo $_smarty_tpl->getValue('objProject')->getDescription();?>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<div class="mt-4">
|
||||||
|
<?php echo $_smarty_tpl->getValue('objProject')->getContent();?>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Formulaire qui envoie la demande au contrôleur (sendEmail) -->
|
||||||
|
<div class="card shadow-sm p-4 mb-5">
|
||||||
|
<form method="post" action="index.php?ctrl=project&action=sendEmail">
|
||||||
|
|
||||||
|
<input type="hidden" name="project_id"
|
||||||
|
value="<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
||||||
|
">
|
||||||
|
|
||||||
|
<input type="email" name="to_email"
|
||||||
|
class="form-control mb-3"
|
||||||
|
placeholder="Adresse email" required>
|
||||||
|
|
||||||
|
<button type="submit" class="btn btn-primary w-100">
|
||||||
|
Envoyer par email
|
||||||
|
</button>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Sidebar : informations du créateur -->
|
||||||
|
<div class="col-lg-4">
|
||||||
|
<div class="card text-center shadow-sm p-4">
|
||||||
|
|
||||||
|
<img src=".<?php echo $_smarty_tpl->getValue('objProject')->getUser_image();?>
|
||||||
|
"
|
||||||
|
class="rounded-circle mb-3 mx-auto"
|
||||||
|
style="width:100px;height:100px;object-fit:cover;">
|
||||||
|
|
||||||
|
<h5><?php echo $_smarty_tpl->getValue('objProject')->getCreatorName();?>
|
||||||
|
</h5>
|
||||||
|
|
||||||
|
<p class="text-muted small">
|
||||||
|
Publié le <?php echo $_smarty_tpl->getValue('objProject')->getCreation_date();?>
|
||||||
|
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<button class="btn btn-primary">Contacter le talent</button>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</main>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* {/block "content"} */
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,115 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 15:03:02
|
||||||
|
from 'file:views/_partial/header.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989f726978651_30802796',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'20a11b6ecdc7e0959bdb519973f0177a783a4561' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/_partial/header.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989f726978651_30802796 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views\\_partial';
|
||||||
|
?><!DOCTYPE html>
|
||||||
|
<html lang="fr">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<link rel="stylesheet" href="assests/css/style.css">
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
||||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.8/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-sRIl4kxILFvY47J16cr9ZwB07vP4J8+LH7qKQnuqkuIAvNWLzeN8tE5YBujZqJLB" crossorigin="anonymous">
|
||||||
|
<?php echo '<script'; ?>
|
||||||
|
src="https://use.fontawesome.com/releases/v6.3.0/js/all.js" crossorigin="anonymous"><?php echo '</script'; ?>
|
||||||
|
>
|
||||||
|
<title>Folliow</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<nav class="navbar navbar-expand-lg navbar-light">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<a class="navbar-brand d-flex align-items-center" href="#">
|
||||||
|
<img src="assests/img/logo.png" alt="Logo" class="logo-image">
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||||
|
<span class="navbar-toggler-icon"></span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<div class="collapse navbar-collapse" id="navbarNav">
|
||||||
|
<ul class="navbar-nav me-auto">
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="?ctrl=&action=">Découvrir</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="?ctrl=&action=">Customisation</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="?ctrl=&action=">Orientation</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="?ctrl=&action=">À propos</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="?ctrl=project&action=search">Rechercher</a>
|
||||||
|
</li>
|
||||||
|
<?php if ((true && (true && null !== ($_SESSION['user'] ?? null)))) {?>
|
||||||
|
<?php if ($_SESSION['user']['authorisation_name'] == "Administrateur") {?>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="?ctrl=admin&action=admin">Admin</a>
|
||||||
|
</li>
|
||||||
|
<?php }?>
|
||||||
|
<?php }?>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<nav class="col-4 d-flex justify-content-end align-items-center" aria-label="Connexion utilisateur">
|
||||||
|
<?php if (!(true && (true && null !== ($_SESSION['user'] ?? null)))) {?>
|
||||||
|
<ul class="navbar-nav">
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="index.php?ctrl=user&action=signin" title="Créer un compte" aria-label="Créer un compte">
|
||||||
|
S'inscrire
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="index.php?ctrl=user&action=login" title="Se connecter" aria-label="Se connecter">
|
||||||
|
Se connecter
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<?php } else { ?>
|
||||||
|
<ul class="navbar-nav">
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="edit_account.php" title="Modifier mon compte" aria-label="Modifier mon compte">
|
||||||
|
<img src=".<?php echo $_SESSION['user']['user_image'];?>
|
||||||
|
"
|
||||||
|
class="rounded-circle flex-shrink-0 mt-2 ml-5"
|
||||||
|
style="width: 36px; height: 36px; object-fit: cover;"
|
||||||
|
alt="Photo de profil">
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="index.php?ctrl=user&action=logout" title="Se déconnecter" aria-label="Se déconnecter">
|
||||||
|
Logout
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<?php }?>
|
||||||
|
</nav>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</nav>
|
||||||
|
</body>
|
||||||
|
</html><?php }
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,81 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 15:03:02
|
||||||
|
from 'file:views/_partial/preview.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989f7269f97f7_68511256',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'3848b4db17319a951391d803dc4119c46e490c52' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/_partial/preview.tpl',
|
||||||
|
1 => 1770646177,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989f7269f97f7_68511256 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views\\_partial';
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<article class="col-md-3 mb-4">
|
||||||
|
<div class="card h-100 shadow-sm article-card">
|
||||||
|
|
||||||
|
<div class="ratio ratio-16x9">
|
||||||
|
<img src=".<?php echo $_smarty_tpl->getValue('objProject')->getThumbnail();?>
|
||||||
|
"
|
||||||
|
class="w-100 h-100 object-fit-cover"
|
||||||
|
alt=""
|
||||||
|
loading="lazy">
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="d-flex align-items-start gap-3">
|
||||||
|
|
||||||
|
<img src=".<?php echo $_smarty_tpl->getValue('objProject')->getUser_image();?>
|
||||||
|
"
|
||||||
|
class="rounded-circle flex-shrink-0 mt-2 ml-5"
|
||||||
|
style="width: 48px; height: 48px; object-fit: cover;"
|
||||||
|
alt="Photo de profil">
|
||||||
|
|
||||||
|
<div class="flex-grow-1 card-body p-3">
|
||||||
|
<h3 class="h6 mb-1"><?php echo $_smarty_tpl->getValue('objProject')->getTitle();?>
|
||||||
|
</h3>
|
||||||
|
|
||||||
|
<small class="text-body-secondary d-block mb-1">
|
||||||
|
<time><?php echo $_smarty_tpl->getValue('objProject')->getCreation_date();?>
|
||||||
|
</time>
|
||||||
|
– <?php echo $_smarty_tpl->getValue('objProject')->getCreatorname();?>
|
||||||
|
|
||||||
|
</small>
|
||||||
|
|
||||||
|
<a href="index.php?ctrl=project&action=display&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
||||||
|
"
|
||||||
|
class="stretched-link small">
|
||||||
|
Lire la suite →
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<?php if ((true && (true && null !== ($_SESSION['user'] ?? null))) && $_SESSION['user']['user_status'] == 2 && $_smarty_tpl->getValue('objProject')->getStatus() == "en_attente") {?>
|
||||||
|
<div class="border rounded text-center">
|
||||||
|
<a class="btn btn-sm m-1 btn-success" href="?ctrl=project&action=accept&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
||||||
|
" name="toPublished">Accepter</a>
|
||||||
|
<a class="btn btn-sm m-1 btn-warning" href="?ctrl=project&action=refuse&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
||||||
|
" name="toRefused">Refuser</a>
|
||||||
|
<a class="btn btn-sm m-1 btn-danger" href="?ctrl=project&action=delete&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
||||||
|
" name="toDelete">Supprimer</a>
|
||||||
|
</div>
|
||||||
|
<?php } elseif ($_smarty_tpl->getValue('projectStatus') == "refusé") {?>
|
||||||
|
<p class="text-danger fw-bold">Portfolio refusé</p>
|
||||||
|
<?php }?>
|
||||||
|
</article><?php }
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,261 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 13:48:33
|
||||||
|
from 'file:views/search.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989e5b1383d99_95399806',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'55cbb497c7dde2dae3a712628e44c1dff2d9365b' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/search.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
'file:views/_partial/preview.tpl' => 1,
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989e5b1383d99_95399806 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
$_smarty_tpl->getInheritance()->init($_smarty_tpl, true);
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$_smarty_tpl->getInheritance()->instanceBlock($_smarty_tpl, 'Block_10517171146989e5b1375aa5_10994726', "content");
|
||||||
|
$_smarty_tpl->getInheritance()->endChild($_smarty_tpl, "views/layout.tpl", $_smarty_current_dir);
|
||||||
|
}
|
||||||
|
/* {block "content"} */
|
||||||
|
class Block_10517171146989e5b1375aa5_10994726 extends \Smarty\Runtime\Block
|
||||||
|
{
|
||||||
|
public function callBlock(\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
?>
|
||||||
|
|
||||||
|
<section aria-label="Blog">
|
||||||
|
<h2 class="visually-hidden">Rechercher parmi les articles</h2>
|
||||||
|
<div class="row mb-2">
|
||||||
|
<section class="mb-5" aria-labelledby="search-heading">
|
||||||
|
<form name="formSearch" method="post" action="?ctrl=project&action=search" class="border rounded p-4 bg-light">
|
||||||
|
<h3 id="search-heading" class="h4 mb-4">
|
||||||
|
<i class="fas fa-search me-2" aria-hidden="true"></i>
|
||||||
|
Rechercher des articles
|
||||||
|
</h3>
|
||||||
|
|
||||||
|
<div class="row g-3">
|
||||||
|
<div class="col-md-6">
|
||||||
|
<label for="keywords" class="form-label">Mots-clés</label>
|
||||||
|
<input
|
||||||
|
value=""
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
id="keywords"
|
||||||
|
name="keywords"
|
||||||
|
placeholder="Ex: JavaScript, CSS..."
|
||||||
|
aria-describedby="keywords-help">
|
||||||
|
<small id="keywords-help" class="form-text text-muted">
|
||||||
|
Recherchez dans les titres et contenus
|
||||||
|
</small>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-6">
|
||||||
|
<label for="author" class="form-label">Auteur</label>
|
||||||
|
<select class="form-select" id="author" name="author">
|
||||||
|
<option value="0" <?php if ($_smarty_tpl->getValue('intAuthor') == 0) {?>selected<?php }?>>Tous les auteurs</option>
|
||||||
|
<?php
|
||||||
|
$_from = $_smarty_tpl->getSmarty()->getRuntime('Foreach')->init($_smarty_tpl, $_smarty_tpl->getValue('arrUser'), 'arrDetUser');
|
||||||
|
$foreach0DoElse = true;
|
||||||
|
foreach ($_from ?? [] as $_smarty_tpl->getVariable('arrDetUser')->value) {
|
||||||
|
$foreach0DoElse = false;
|
||||||
|
?>
|
||||||
|
<option value="<?php echo $_smarty_tpl->getValue('arrDetUser')['user_id'];?>
|
||||||
|
"
|
||||||
|
<?php if ($_smarty_tpl->getValue('intAuthor') == $_smarty_tpl->getValue('arrDetUser')['user_id']) {?>selected<?php }?>
|
||||||
|
>
|
||||||
|
<?php echo $_smarty_tpl->getValue('arrDetUser')['user_firstname'];?>
|
||||||
|
<?php echo $_smarty_tpl->getValue('arrDetUser')['user_name'];?>
|
||||||
|
|
||||||
|
</option>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
$_smarty_tpl->getSmarty()->getRuntime('Foreach')->restore($_smarty_tpl, 1);?>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="col-6">
|
||||||
|
<fieldset>
|
||||||
|
<legend class="form-label">Type de recherche par date</legend>
|
||||||
|
<div class="form-check form-check-inline">
|
||||||
|
<input
|
||||||
|
class="form-check-input"
|
||||||
|
type="radio"
|
||||||
|
name="period"
|
||||||
|
id="period-exact"
|
||||||
|
value="0"
|
||||||
|
<?php if ($_smarty_tpl->getValue('intPeriod') == 0) {?>checked<?php }?>
|
||||||
|
aria-controls="date-exact date-range">
|
||||||
|
<label class="form-check-label" for="period-exact">
|
||||||
|
Date exacte
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-check form-check-inline">
|
||||||
|
<input
|
||||||
|
class="form-check-input"
|
||||||
|
type="radio"
|
||||||
|
name="period"
|
||||||
|
id="period-range"
|
||||||
|
value="1"
|
||||||
|
<?php if ($_smarty_tpl->getValue('intPeriod') == 1) {?>checked<?php }?>
|
||||||
|
aria-controls="date-exact date-range">
|
||||||
|
<label class="form-check-label" for="period-range">
|
||||||
|
Période
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
</div>
|
||||||
|
<!-- AJOUT RECHERCHE PAR CATEGORIE -->
|
||||||
|
<div class="col-6">
|
||||||
|
<fieldset>
|
||||||
|
<legend class="form-label">Type de recherche par catégories</legend>
|
||||||
|
<div class="col-md-6">
|
||||||
|
<label for="author" class="form-label">Catégorie</label>
|
||||||
|
<select class="form-select" id="category" name="category">
|
||||||
|
<option value="0" <?php if ($_smarty_tpl->getValue('intCategory') == 0) {?>selected<?php }?>>Toutes les catégories</option>
|
||||||
|
<?php
|
||||||
|
$_from = $_smarty_tpl->getSmarty()->getRuntime('Foreach')->init($_smarty_tpl, $_smarty_tpl->getValue('arrCategory'), 'arrDetCategory');
|
||||||
|
$foreach1DoElse = true;
|
||||||
|
foreach ($_from ?? [] as $_smarty_tpl->getVariable('arrDetCategory')->value) {
|
||||||
|
$foreach1DoElse = false;
|
||||||
|
?>
|
||||||
|
<option value="<?php echo $_smarty_tpl->getValue('arrDetCategory')['category_id'];?>
|
||||||
|
"
|
||||||
|
<?php if ($_smarty_tpl->getValue('intCategory') == $_smarty_tpl->getValue('arrDetCategory')['category_id']) {?>selected<?php }?>
|
||||||
|
>
|
||||||
|
<?php echo $_smarty_tpl->getValue('arrDetCategory')['category_name'];?>
|
||||||
|
|
||||||
|
</option>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
$_smarty_tpl->getSmarty()->getRuntime('Foreach')->restore($_smarty_tpl, 1);?>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</fieldset>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-6" id="date-exact">
|
||||||
|
<label for="date" class="form-label">Date</label>
|
||||||
|
<input
|
||||||
|
type="date"
|
||||||
|
class="form-control"
|
||||||
|
id="date"
|
||||||
|
name="date"
|
||||||
|
aria-describedby="date-help"
|
||||||
|
value="<?php echo $_smarty_tpl->getValue('strDate');?>
|
||||||
|
" >
|
||||||
|
<small id="date-help" class="form-text text-muted">
|
||||||
|
Format: JJ/MM/AAAA
|
||||||
|
</small>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="date-range" style="display: none;">
|
||||||
|
<div class="row g-3">
|
||||||
|
<div class="col-md-6">
|
||||||
|
<label for="startdate" class="form-label">Date de début</label>
|
||||||
|
<input
|
||||||
|
type="date"
|
||||||
|
class="form-control"
|
||||||
|
id="startdate"
|
||||||
|
name="startdate"
|
||||||
|
value="<?php echo $_smarty_tpl->getValue('strStartDate');?>
|
||||||
|
" >
|
||||||
|
</div>
|
||||||
|
<div class="col-md-6">
|
||||||
|
<label for="enddate" class="form-label">Date de fin</label>
|
||||||
|
<input
|
||||||
|
type="date"
|
||||||
|
class="form-control"
|
||||||
|
id="enddate"
|
||||||
|
name="enddate"
|
||||||
|
value="<?php echo $_smarty_tpl->getValue('strEndDate');?>
|
||||||
|
" >
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-12">
|
||||||
|
<button type="submit" class="btn btn-primary">
|
||||||
|
<i class="fas fa-search me-2" aria-hidden="true"></i>
|
||||||
|
Rechercher
|
||||||
|
</button>
|
||||||
|
<button type="reset" class="btn btn-secondary ms-2">
|
||||||
|
<i class="fas fa-redo me-2" aria-hidden="true"></i>
|
||||||
|
Réinitialiser
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<!-- Liste des articles -->
|
||||||
|
<section aria-labelledby="articles-heading">
|
||||||
|
<h3 id="articles-heading" class="visually-hidden">Liste des projets</h3>
|
||||||
|
<div class="row mb-2">
|
||||||
|
<?php if ($_smarty_tpl->getSmarty()->getModifierCallback('count')($_smarty_tpl->getValue('arrProject')) == 0) {?>
|
||||||
|
<div class="alert alert-warning">
|
||||||
|
<p>Pas de résultats</p>
|
||||||
|
</div>
|
||||||
|
<?php }?>
|
||||||
|
<?php
|
||||||
|
$_from = $_smarty_tpl->getSmarty()->getRuntime('Foreach')->init($_smarty_tpl, $_smarty_tpl->getValue('arrProjectToDisplay'), 'objProject');
|
||||||
|
$foreach2DoElse = true;
|
||||||
|
foreach ($_from ?? [] as $_smarty_tpl->getVariable('objProject')->value) {
|
||||||
|
$foreach2DoElse = false;
|
||||||
|
?>
|
||||||
|
<?php $_smarty_tpl->renderSubTemplate("file:views/_partial/preview.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), (int) 0, $_smarty_current_dir);
|
||||||
|
?>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
$_smarty_tpl->getSmarty()->getRuntime('Foreach')->restore($_smarty_tpl, 1);?>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
<?php echo '<script'; ?>
|
||||||
|
>
|
||||||
|
// Gestion de l'affichage des champs de date
|
||||||
|
const periodRadios = document.querySelectorAll('input[name="period"]');
|
||||||
|
const dateExact = document.getElementById('date-exact');
|
||||||
|
const dateRange = document.getElementById('date-range');
|
||||||
|
|
||||||
|
function toggleDateFields() {
|
||||||
|
const selectedPeriod = document.querySelector('input[name="period"]:checked').value;
|
||||||
|
|
||||||
|
if (selectedPeriod === '0') {
|
||||||
|
dateExact.style.display = 'block';
|
||||||
|
dateRange.style.display = 'none';
|
||||||
|
} else {
|
||||||
|
dateExact.style.display = 'none';
|
||||||
|
dateRange.style.display = 'block';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
periodRadios.forEach(radio => {
|
||||||
|
radio.addEventListener('change', toggleDateFields);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Initialisation au chargement
|
||||||
|
toggleDateFields();
|
||||||
|
<?php echo '</script'; ?>
|
||||||
|
>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* {/block "content"} */
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,50 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 15:03:02
|
||||||
|
from 'file:views/layout.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989f726914163_83904848',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'708269d7487a64eac6b48ed73fcd1924b1bda41b' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/layout.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
'file:views/_partial/header.tpl' => 1,
|
||||||
|
'file:views/_partial/footer.tpl' => 1,
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989f726914163_83904848 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
$_smarty_tpl->getInheritance()->init($_smarty_tpl, false);
|
||||||
|
$_smarty_tpl->renderSubTemplate("file:views/_partial/header.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), (int) 0, $_smarty_current_dir);
|
||||||
|
?>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$_smarty_tpl->getInheritance()->instanceBlock($_smarty_tpl, 'Block_14089017836989f726912e95_86271581', "content");
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php $_smarty_tpl->renderSubTemplate("file:views/_partial/footer.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), (int) 0, $_smarty_current_dir);
|
||||||
|
}
|
||||||
|
/* {block "content"} */
|
||||||
|
class Block_14089017836989f726912e95_86271581 extends \Smarty\Runtime\Block
|
||||||
|
{
|
||||||
|
public function callBlock(\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* {/block "content"} */
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,71 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 15:03:02
|
||||||
|
from 'file:views/home.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989f72687e0c8_78461032',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'7e6dbbb1e41ad859e7f5b7b444b7670474263f88' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/home.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
'file:views/_partial/preview.tpl' => 1,
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989f72687e0c8_78461032 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
$_smarty_tpl->getInheritance()->init($_smarty_tpl, true);
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$_smarty_tpl->getInheritance()->instanceBlock($_smarty_tpl, 'Block_15962470546989f72687a521_39502617', "content");
|
||||||
|
?>
|
||||||
|
|
||||||
|
<?php $_smarty_tpl->getInheritance()->endChild($_smarty_tpl, "views/layout.tpl", $_smarty_current_dir);
|
||||||
|
}
|
||||||
|
/* {block "content"} */
|
||||||
|
class Block_15962470546989f72687a521_39502617 extends \Smarty\Runtime\Block
|
||||||
|
{
|
||||||
|
public function callBlock(\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
?>
|
||||||
|
|
||||||
|
<section class="container mt-5 p-5 d-flex flex-column align-items-center text-center">
|
||||||
|
<h1 class="logo">Folliow</h1>
|
||||||
|
<h2>Là où les talents rencontrent leur avenir</h2>
|
||||||
|
<p class="col-6">Une plateforme de portfolio adapté à vos besoins et aux besoins des entreprises.
|
||||||
|
Créer un portfolio réellement pertinent aux exigences du marché et rentrez
|
||||||
|
directement en contact avec les entreprises.</p>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<section class="container" aria-label="Articles récents">
|
||||||
|
<h2 class="visually-hidden">Les 4 derniers articles</h2>
|
||||||
|
<div class="row mb-2">
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$_from = $_smarty_tpl->getSmarty()->getRuntime('Foreach')->init($_smarty_tpl, $_smarty_tpl->getValue('arrProjectToDisplay'), 'objProject');
|
||||||
|
$foreach0DoElse = true;
|
||||||
|
foreach ($_from ?? [] as $_smarty_tpl->getVariable('objProject')->value) {
|
||||||
|
$foreach0DoElse = false;
|
||||||
|
?>
|
||||||
|
<?php $_smarty_tpl->renderSubTemplate("file:views/_partial/preview.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), (int) 0, $_smarty_current_dir);
|
||||||
|
?>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
$_smarty_tpl->getSmarty()->getRuntime('Foreach')->restore($_smarty_tpl, 1);?>
|
||||||
|
</section>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* {/block "content"} */
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,164 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 15:02:52
|
||||||
|
from 'file:views/login.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989f71c761896_25894348',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'b7b39f4634df66c24660dc5baa93ac9d38bfe874' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/login.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989f71c761896_25894348 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
$_smarty_tpl->getInheritance()->init($_smarty_tpl, true);
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$_smarty_tpl->getInheritance()->instanceBlock($_smarty_tpl, 'Block_19992775976989f71c758fc2_34188356', "content");
|
||||||
|
$_smarty_tpl->getInheritance()->endChild($_smarty_tpl, "views/layout.tpl", $_smarty_current_dir);
|
||||||
|
}
|
||||||
|
/* {block "content"} */
|
||||||
|
class Block_19992775976989f71c758fc2_34188356 extends \Smarty\Runtime\Block
|
||||||
|
{
|
||||||
|
public function callBlock(\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views';
|
||||||
|
?>
|
||||||
|
|
||||||
|
<section aria-label="Se connecter">
|
||||||
|
<?php if ($_smarty_tpl->getSmarty()->getModifierCallback('count')($_smarty_tpl->getValue('arrError')) > 0) {?>
|
||||||
|
<div class="alert alert-danger">
|
||||||
|
<?php
|
||||||
|
$_from = $_smarty_tpl->getSmarty()->getRuntime('Foreach')->init($_smarty_tpl, $_smarty_tpl->getValue('arrError'), 'strError');
|
||||||
|
$foreach0DoElse = true;
|
||||||
|
foreach ($_from ?? [] as $_smarty_tpl->getVariable('strError')->value) {
|
||||||
|
$foreach0DoElse = false;
|
||||||
|
?>
|
||||||
|
<p><?php echo $_smarty_tpl->getValue('strError');?>
|
||||||
|
</p>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
$_smarty_tpl->getSmarty()->getRuntime('Foreach')->restore($_smarty_tpl, 1);?>
|
||||||
|
</div>
|
||||||
|
<?php }?>
|
||||||
|
<!-- Contenu principal de la page -->
|
||||||
|
<main class="container py-5">
|
||||||
|
|
||||||
|
<!-- Centrage horizontal du formulaire -->
|
||||||
|
<div class="row justify-content-center">
|
||||||
|
<!-- Contenu principal de la page -->
|
||||||
|
<main class="container py-5">
|
||||||
|
|
||||||
|
<!-- Centrage horizontal du formulaire -->
|
||||||
|
<div class="row justify-content-center">
|
||||||
|
<div class="col-12 col-md-8 col-lg-5">
|
||||||
|
|
||||||
|
<!-- Carte contenant le formulaire de connexion -->
|
||||||
|
<div class="card shadow-sm border-0 rounded-4 p-4 p-lg-5">
|
||||||
|
|
||||||
|
<!-- Titre principal -->
|
||||||
|
<h1 class="h3 fw-bold mb-1">Connexion</h1>
|
||||||
|
|
||||||
|
<!-- Texte descriptif -->
|
||||||
|
<p class="text-secondary mb-4">
|
||||||
|
Connectez-vous à votre compte.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<!-- Formulaire de connexion -->
|
||||||
|
<!-- Le traitement sera effectué en PHP via la méthode POST -->
|
||||||
|
<form method="POST">
|
||||||
|
|
||||||
|
<div class="row g-3">
|
||||||
|
|
||||||
|
<!-- Champ : adresse e-mail de l'utilisateur -->
|
||||||
|
<div class="col-12">
|
||||||
|
<label for="user_mail" class="form-label">
|
||||||
|
Adresse e-mail
|
||||||
|
</label>
|
||||||
|
<input
|
||||||
|
value="<?php echo (($tmp = $_smarty_tpl->getValue('strMail') ?? null)===null||$tmp==='' ? '' ?? null : $tmp);?>
|
||||||
|
"
|
||||||
|
type="email"
|
||||||
|
class="form-control <?php if ((true && (true && null !== ($_smarty_tpl->getValue('arrError')['mail'] ?? null)))) {?>is-invalid<?php }?>"
|
||||||
|
id="user_mail"
|
||||||
|
name="user_mail"
|
||||||
|
required
|
||||||
|
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Champ : mot de passe -->
|
||||||
|
<div class="col-12">
|
||||||
|
<label for="user_password" class="form-label">
|
||||||
|
Mot de passe
|
||||||
|
</label>
|
||||||
|
<input
|
||||||
|
type="password"
|
||||||
|
class="form-control <?php if ((true && (true && null !== ($_smarty_tpl->getValue('arrError')['pwd'] ?? null)))) {?>is-invalid<?php }?>"
|
||||||
|
id="user_password"
|
||||||
|
name="user_password"
|
||||||
|
required
|
||||||
|
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Option "Se souvenir de moi" (fonctionnalité optionnelle côté PHP) -->
|
||||||
|
<div class="col-12">
|
||||||
|
<div class="form-check">
|
||||||
|
<input class="form-check-input" type="checkbox" id="remember_me" name="remember_me">
|
||||||
|
<label class="form-check-label" for="remember_me">
|
||||||
|
Se souvenir de moi
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Bouton de soumission du formulaire -->
|
||||||
|
<div class="col-12 d-grid mt-2">
|
||||||
|
<button type="submit" class="btn btn-primary btn-lg rounded-3">
|
||||||
|
Se connecter
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Lien vers la page d'inscription -->
|
||||||
|
<div class="col-12 text-center">
|
||||||
|
<small class="text-secondary">
|
||||||
|
Pas encore de compte ?
|
||||||
|
<a href="index.php?ctrl=user&action=signin" class="link-primary">Créer un compte</a>
|
||||||
|
</small>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Lien pour la récupération du mot de passe -->
|
||||||
|
<div class="col-12 text-center">
|
||||||
|
<small>
|
||||||
|
<a href="#" class="link-primary">
|
||||||
|
Mot de passe oublié ?
|
||||||
|
</a>
|
||||||
|
</small>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</main>
|
||||||
|
</section>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* {/block "content"} */
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,63 @@
|
||||||
|
<?php
|
||||||
|
/* Smarty version 5.7.0, created on 2026-02-09 15:03:02
|
||||||
|
from 'file:views/_partial/footer.tpl' */
|
||||||
|
|
||||||
|
/* @var \Smarty\Template $_smarty_tpl */
|
||||||
|
if ($_smarty_tpl->getCompiled()->isFresh($_smarty_tpl, array (
|
||||||
|
'version' => '5.7.0',
|
||||||
|
'unifunc' => 'content_6989f726ac4850_67307943',
|
||||||
|
'has_nocache_code' => false,
|
||||||
|
'file_dependency' =>
|
||||||
|
array (
|
||||||
|
'cef94db5b9dde613f0f79dcacc6c7b4e161e98a2' =>
|
||||||
|
array (
|
||||||
|
0 => 'views/_partial/footer.tpl',
|
||||||
|
1 => 1770639154,
|
||||||
|
2 => 'file',
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'includes' =>
|
||||||
|
array (
|
||||||
|
),
|
||||||
|
))) {
|
||||||
|
function content_6989f726ac4850_67307943 (\Smarty\Template $_smarty_tpl) {
|
||||||
|
$_smarty_current_dir = 'C:\\wamp64\\www\\Folliow\\projet_php-guillaume\\views\\_partial';
|
||||||
|
?>
|
||||||
|
<footer class="footer container-fluid d-flex justify-content-around">
|
||||||
|
<div class="col-3">
|
||||||
|
<ul>
|
||||||
|
<li><a href="#">Découvrir</a>
|
||||||
|
<li><a href="#">Customisation</a>
|
||||||
|
<li><a href="#">Emploi</a>
|
||||||
|
<li><a href="#">A propos</a>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="col-3">
|
||||||
|
<ul>
|
||||||
|
<li><a href="#">Recruter</a>
|
||||||
|
<li><a href="#">Partenariat</a>
|
||||||
|
<li><a href="#">Blog</a>
|
||||||
|
<li><a href="#">Aide et support</a>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="col-3">
|
||||||
|
<ul>
|
||||||
|
<li><a href="#">Politique de confidentialité</a>
|
||||||
|
<li><a href="#">Politique sur les données</a>
|
||||||
|
<li><a href="#">CGU</a>
|
||||||
|
<li><a href="#">CGV</a>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="col-3">
|
||||||
|
<p>Suivez-nous</p>
|
||||||
|
</div>
|
||||||
|
</footer>
|
||||||
|
<?php echo '<script'; ?>
|
||||||
|
src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js" crossorigin="anonymous"><?php echo '</script'; ?>
|
||||||
|
>
|
||||||
|
<?php echo '<script'; ?>
|
||||||
|
src="js/scripts.js"><?php echo '</script'; ?>
|
||||||
|
>
|
||||||
|
</body>
|
||||||
|
</html><?php }
|
||||||
|
}
|
||||||
|
|
@ -14,28 +14,40 @@
|
||||||
|
|
||||||
<div class="d-flex align-items-start gap-3">
|
<div class="d-flex align-items-start gap-3">
|
||||||
|
|
||||||
{* PHOTO DE PROFIL *}
|
{* PHOTO DE PROFIL *}
|
||||||
<img src=".{$objProject->getUser_image()}"
|
<img src=".{$objProject->getUser_image()}"
|
||||||
class="rounded-circle flex-shrink-0 mt-2 ml-5"
|
class="rounded-circle flex-shrink-0 mt-2 ml-5"
|
||||||
style="width: 48px; height: 48px; object-fit: cover;"
|
style="width: 48px; height: 48px; object-fit: cover;"
|
||||||
alt="Photo de profil">
|
alt="Photo de profil">
|
||||||
|
|
||||||
{* INFOS *}
|
{* INFOS *}
|
||||||
<div class="flex-grow-1 card-body p-3">
|
<div class="flex-grow-1 card-body p-3">
|
||||||
<h3 class="h6 mb-1">{$objProject->getTitle()}</h3>
|
<h3 class="h6 mb-1">{$objProject->getTitle()}</h3>
|
||||||
|
|
||||||
<small class="text-body-secondary d-block mb-1">
|
<small class="text-body-secondary d-block mb-1">
|
||||||
<time>{$objProject->getCreation_date()}</time>
|
<time>{$objProject->getCreation_date()}</time>
|
||||||
– {$objProject->getCreatorname()}
|
– {$objProject->getCreatorname()}
|
||||||
</small>
|
</small>
|
||||||
|
|
||||||
<a href="index.php?ctrl=project&action=display&id={$objProject->getId()}"
|
<a href="index.php?ctrl=project&action=display&id={$objProject->getId()}"
|
||||||
class="stretched-link small">
|
class="stretched-link small">
|
||||||
Lire la suite →
|
Lire la suite →
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
{*Controle de l'utilisateur ainsi que du status du projet*}
|
||||||
|
{if isset($smarty.session.user)
|
||||||
|
and $smarty.session.user.user_status == 2
|
||||||
|
and $objProject->getStatus() eq "en_attente"}
|
||||||
|
<div class="border rounded text-center">
|
||||||
|
<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>
|
||||||
|
<a class="btn btn-sm m-1 btn-danger" href="?ctrl=project&action=delete&id={$objProject->getId()}" name="toDelete">Supprimer</a>
|
||||||
|
</div>
|
||||||
|
{elseif $projectStatus eq "refusé"}
|
||||||
|
<p class="text-danger fw-bold">Portfolio refusé</p>
|
||||||
|
{/if}
|
||||||
</article>
|
</article>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue