fix migrate
Deploy HouseHub / deploy (push) Successful in 2s

This commit is contained in:
2026-06-17 12:40:18 +02:00
parent d6e95c1b2a
commit 96df90d372
4 changed files with 605 additions and 35 deletions
+2 -1
View File
@@ -231,7 +231,8 @@ while ($item = $stmt->fetch(PDO::FETCH_ASSOC)) {
$amt = ($item['type'] === 'Annuel') ? $absAmount / 12 : $absAmount;
$name = trim($item['name']);
$catCode = $item['category']; // Ex: FIXED, FMCG, INCOME...
$isIncome = ((float)$item['amount'] > 0); // La norme est désormais définie par le signe du montant
$isIncome = (isset($categoriesConfig[$catCode]) && $categoriesConfig[$catCode]['db_type'] === 'Income');
if ($isIncome) {
$incomeList[] = ['id' => $item['id'], 'name' => $name, 'amount' => $absAmount];