115 lines
5.2 KiB
PHP
115 lines
5.2 KiB
PHP
<?php
|
|
/* Smarty version 5.7.0, created on 2026-02-22 17:49:49
|
|
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_699b41bd0e6f98_46719655',
|
|
'has_nocache_code' => false,
|
|
'file_dependency' =>
|
|
array (
|
|
'67e1ae3a210fc2d1bf8782993687bad91a1cf0f6' =>
|
|
array (
|
|
0 => 'views/_partial/preview.tpl',
|
|
1 => 1771765950,
|
|
2 => 'file',
|
|
),
|
|
),
|
|
'includes' =>
|
|
array (
|
|
),
|
|
))) {
|
|
function content_699b41bd0e6f98_46719655 (\Smarty\Template $_smarty_tpl) {
|
|
$_smarty_current_dir = 'D:\\projetphp\\views\\_partial';
|
|
?><article class="col-md-3 mb-5 <?php if ((true && (true && null !== ($_SESSION['user'] ?? null))) && $_SESSION['user']['user_status'] == 2) {?> pb-5 <?php }?>" style="border-radius: 100px ;">
|
|
<div class="card h-100 shadow article-card rounded-4" style="border-width: 2px; overflow: hidden;">
|
|
|
|
<div class="ratio ratio-4x3">
|
|
<img src="<?php echo $_ENV['IMG_PROJECT_PATH'];
|
|
echo $_smarty_tpl->getValue('objProject')->getThumbnail();?>
|
|
"
|
|
class="w-100 h-100 object-fit-cover"
|
|
alt=""
|
|
loading="lazy">
|
|
</div>
|
|
|
|
<div class="card-body p-3 bg-light">
|
|
<div class="d-flex align-items-start gap-3">
|
|
<img src="<?php echo $_ENV['IMG_USER_PATH'];
|
|
echo $_smarty_tpl->getValue('objProject')->getUser_image();?>
|
|
"
|
|
class="rounded-circle flex-shrink-0 border border-2 border-white"
|
|
style="width: 64px; height: 64px; object-fit: cover; margin-top: 8px;"
|
|
alt="Photo de profil">
|
|
|
|
<div class="flex-grow-1">
|
|
<h3 class="h6 fw-bold mb-2 mt-1"><?php echo $_smarty_tpl->getValue('objProject')->getTitle();?>
|
|
</h3>
|
|
<p class="small text-muted mb-1">
|
|
<i class="bi bi-person"></i>
|
|
<a href="index.php?ctrl=user&action=user&pseudo=<?php echo $_smarty_tpl->getValue('objProject')->getCreatorname();?>
|
|
"
|
|
class="text-decoration-none text-muted"
|
|
style="position: relative; z-index: 2;">
|
|
<?php echo $_smarty_tpl->getValue('objProject')->getCreatorname();?>
|
|
|
|
</a>
|
|
</p>
|
|
<p class="small text-muted mb-0">
|
|
<i class="bi bi-geo-alt"></i> Colmar
|
|
</p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="d-flex justify-content-between align-items-center mt-3">
|
|
<small class="text-muted">
|
|
<i class="bi bi-clock"></i> <time><?php echo $_smarty_tpl->getValue('objProject')->getCreation_date();?>
|
|
</time>
|
|
</small>
|
|
<?php if ($_smarty_tpl->getValue('objProject')->getStatus() != "refusé") {?>
|
|
<a href="index.php?ctrl=project&action=display&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
|
"
|
|
class="btn btn-sm btn-primary">
|
|
Voir →
|
|
</a>
|
|
<?php }?>
|
|
</div>
|
|
|
|
<?php if ((true && (true && null !== ($_SESSION['user'] ?? null)))) {?>
|
|
<?php if ($_SESSION['user']['user_id'] == $_smarty_tpl->getValue('objProject')->getUser_id()) {?>
|
|
<a href="index.php?ctrl=project&action=display&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
|
"
|
|
class="btn btn-sm btn-outline-secondary mt-2 w-100"
|
|
style="position: relative; z-index: 2;">
|
|
Editer
|
|
</a>
|
|
<?php }?>
|
|
<?php }?>
|
|
</div>
|
|
|
|
<?php if ((true && (true && null !== ($_SESSION['user'] ?? null))) && $_SESSION['user']['user_status'] == 2 && $_smarty_tpl->getValue('objProject')->getStatus() == "en_attente") {?>
|
|
<div class="card-footer bg-white border-top-0 p-2">
|
|
<div class="d-flex gap-2">
|
|
<a class="btn btn-sm btn-success flex-fill"
|
|
href="?ctrl=project&action=accept&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
|
"
|
|
name="toPublished">Accepter</a>
|
|
<a class="btn btn-sm btn-warning flex-fill"
|
|
href="?ctrl=project&action=refuse&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
|
"
|
|
name="toRefused">Refuser</a>
|
|
<a class="btn btn-sm btn-danger flex-fill"
|
|
href="?ctrl=project&action=delete&id=<?php echo $_smarty_tpl->getValue('objProject')->getId();?>
|
|
"
|
|
name="toDelete">Supprimer</a>
|
|
</div>
|
|
</div>
|
|
<?php } elseif ($_smarty_tpl->getValue('objProject')->getStatus() == "refusé") {?>
|
|
<div class="card-footer bg-white border-top-0 p-2">
|
|
<p class="text-danger fw-bold text-center mb-0 small">Portfolio refusé</p>
|
|
</div>
|
|
<?php }?>
|
|
</div>
|
|
</article><?php }
|
|
}
|