pour prod

This commit is contained in:
Loic Masi
2026-08-07 16:13:43 +02:00
commit 5fbf76868f
157 changed files with 24085 additions and 0 deletions

26
app/Models/MotifModel.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
declare(strict_types=1);
namespace App\Models;
final class MotifModel extends BaseModel
{
public function allActive(): array
{
return $this->pdo->query(
"SELECT id_motif, code, libelle, compte_dans_quota
FROM motif_planning
WHERE actif = TRUE
ORDER BY ordre_affichage, libelle"
)->fetchAll();
}
public function activeIds(): array
{
return array_map(
'intval',
$this->pdo->query('SELECT id_motif FROM motif_planning WHERE actif = TRUE')->fetchAll(\PDO::FETCH_COLUMN)
);
}
}