amélrioration

This commit is contained in:
2026-06-18 21:45:05 +02:00
parent fea1d787ca
commit b2e73b4fe7
3 changed files with 249 additions and 31 deletions
+9
View File
@@ -2003,4 +2003,13 @@ console.log('[DB] Migrations 2FA OK');
}
}
{
// Migration : assigned_to sur tickets
const cols = db.prepare("PRAGMA table_info(tickets)").all().map(c => c.name);
if (!cols.includes('assigned_to')) {
db.exec("ALTER TABLE tickets ADD COLUMN assigned_to INTEGER REFERENCES users(id) ON DELETE SET NULL");
console.log('[DB] tickets: colonne assigned_to ajoutée');
}
}
export default db;