app perfect

This commit is contained in:
2026-03-20 10:42:30 +01:00
parent 112d0136c9
commit d3d3ba3586
6 changed files with 463 additions and 69 deletions
+8
View File
@@ -101,4 +101,12 @@ class PokedexDatabase {
int count = result.isNotEmpty ? (result.first.values.first as int? ?? 0) : 0;
return count;
}
// Obtenir le nombre de pokémon vus
static Future<int> getSeenCount() async {
Database database = await getDatabase();
var result = await database.rawQuery("SELECT COUNT(*) FROM pokemon WHERE isSeen = 1");
int count = result.isNotEmpty ? (result.first.values.first as int? ?? 0) : 0;
return count;
}
}