Initial commit: CLEO ERP avec améliorations debug

- Configuration du debug conditionnel pour dev/recette
- Fonction debug() globale avec niveaux
- Logging des requêtes SQL
- Handlers d'exceptions et d'erreurs globaux

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-07-04 10:24:52 +02:00
commit 99021b4f42
7348 changed files with 11423897 additions and 0 deletions

16
models/mclients.php Normal file
View File

@@ -0,0 +1,16 @@
<?php
$sch = "";
if ($_POST) {
if (isset($_POST["schClients"])) {
$search = nettoie_input(trim($_POST["schClients"]));
$sch = 'c.libelle LIKE "%' . $search . '%" OR c.adresse1 LIKE "%' . $search . '%" OR c.cp LIKE "%' . $search . '%" OR c.ville LIKE "%' . $search . '%" OR c.contact_nom LIKE "%' . $search . '%" OR c.contact_prenom LIKE "%' . $search . '%" OR c.contact_fonction LIKE "%' . $search . '%" ';
}
}
//! On récupère la liste des clients
$sql = 'SELECT c.* FROM clients c ';
if ($sch != "") {
$sql .= 'WHERE ' . $sch;
}
$sql .= 'ORDER BY c.libelle';
$aModel["clients"] = getinfos($sql, "gen");