- Complete MVP with Repository Pattern, SQLite storage - Provider + ChangeNotifier state management - Navigation 2.0 with deep link support - Habit CRUD with twoDayRule, notifications, categories - Backup/Restore via JSON - Statistics with streak tracking - Material You theme support - Biometric lock support - Desktop widget support - 27 languages i18n structure - Comprehensive test suite (87/89 passing)
26 lines
606 B
Dart
26 lines
606 B
Dart
class BackupData {
|
|
final int version;
|
|
final List<Map<String, dynamic>> habits;
|
|
final List<Map<String, dynamic>> categories;
|
|
final List<Map<String, dynamic>> habitCategories;
|
|
final Map<String, dynamic> metadata;
|
|
|
|
BackupData({
|
|
this.version = 3,
|
|
this.habits = const [],
|
|
this.categories = const [],
|
|
this.habitCategories = const [],
|
|
this.metadata = const {},
|
|
});
|
|
|
|
Map<String, dynamic> toJson() {
|
|
return {
|
|
'version': version,
|
|
'habits': habits,
|
|
'categories': categories,
|
|
'habit_categories': habitCategories,
|
|
'metadata': metadata,
|
|
};
|
|
}
|
|
}
|