Merge pull request #4 from Yasder5/laura

Laura
This commit is contained in:
Yass 2026-01-19 13:06:13 +01:00 committed by GitHub
commit 046bce1849
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 206 additions and 40 deletions

View file

@ -11,7 +11,7 @@
<div class="row mb-2">
<?php
foreach($arrProjectToDiplay as $objProject){
include("../app/views/partials/project.php");
include("../app/views/partials/preview.php");
}
?>
</section>

31
app/views/project.php Normal file
View file

@ -0,0 +1,31 @@
<body>
<section class="container mt-5 p-5 d-flex flex-column align-items-center">
<div>
<h2>Alimenter votre projet</h2>
<button type="button" class="btn btn-primary btn-lg">+</button>
</div>
<div>
<h3>Description</h3>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
</div>
<div>
<h3>Photos behind the scene</h3>
<div class="row mb-2">
<img >
</div>
</div>
<div>
<h3>Other projects</h3>
<div class="row mb-2">
<?php
foreach($arrProjectToDiplay as $objProject){
include("../app/views/partials/preview.php");
}
?>
</div>
</div>
</div>
<section>
</body>

View file

@ -27,13 +27,23 @@
<div class="col-md-6">
<label for="author" class="form-label">Auteur</label>
<select class="form-select" id="author" name="author">
<option value="0">Tous les auteurs</option>
<option value="0" <?php echo ($intAuthor == 0)?'selected':''; ?>>Tous les auteurs</option>
<?php
foreach($arrUser as $arrDetUser){
?>
<option value="<?php echo $arrDetUser['user_id']; ?>"
<?php echo ($intAuthor == $arrDetUser['user_id'])?'selected':''; ?>
>
<?php echo $arrDetUser['user_firstname'].' '.$arrDetUser['user_name']; ?>
</option>
<?php
}
?>
</select>
</div>
<div class="col-12">
<div class="col-6">
<fieldset>
<legend class="form-label">Type de recherche par date</legend>
<div class="form-check form-check-inline">
@ -43,6 +53,7 @@
name="period"
id="period-exact"
value="0"
<?php echo ($intPeriod == 0)?'checked':'' ; ?>
aria-controls="date-exact date-range">
<label class="form-check-label" for="period-exact">
Date exacte
@ -55,6 +66,7 @@
name="period"
id="period-range"
value="1"
<?php echo ($intPeriod == 1)?'checked':'' ; ?>
aria-controls="date-exact date-range">
<label class="form-check-label" for="period-range">
Période
@ -62,6 +74,29 @@
</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 echo ($intCategory == 0)?'selected':''; ?>>Toutes les catégories</option>
<?php
foreach($arrCategory as $arrDetCategory){
?>
<option value="<?php echo $arrDetCategory['category_id']; ?>"
<?php echo ($intCategory == $arrDetCategory['category_id'])?'selected':''; ?>
>
<?php echo $arrDetCategory['category_name']; ?>
</option>
<?php
}
?>
</select>
</div>
</fieldset>
</div>
<div class="col-md-6" id="date-exact">
<label for="date" class="form-label">Date</label>
@ -71,7 +106,7 @@
id="date"
name="date"
aria-describedby="date-help"
value="" >
value="<?php echo $strDate; ?>" >
<small id="date-help" class="form-text text-muted">
Format: JJ/MM/AAAA
</small>
@ -86,7 +121,7 @@
class="form-control"
id="startdate"
name="startdate"
value="" >
value="<?php echo $strStartDate; ?>" >
</div>
<div class="col-md-6">
<label for="enddate" class="form-label">Date de fin</label>
@ -95,7 +130,7 @@
class="form-control"
id="enddate"
name="enddate"
value="" >
value="<?php echo $strEndDate; ?>" >
</div>
</div>
</div>
@ -118,18 +153,18 @@
<section aria-labelledby="articles-heading">
<h3 id="articles-heading" class="visually-hidden">Liste des projets</h3>
<div class="row mb-2">
<?php
if (count($arrProject) == 0){
?>
<div class="alert alert-warning">
<p>Pas de résultats</p>
</div>
<?php
}
foreach($arrProjectToDisplay as $objProject){
include("../app/views/partials/project.php");
} ?>
<?php
if (count($arrProject) == 0){
?>
<div class="alert alert-warning">
<p>Pas de résultats</p>
</div>
<?php
}
foreach($arrProjectToDisplay as $objProject){
include("../app/views/partials/preview.php");
} ?>
</div>
</section>
</div>
</section>
</div>
</section>