Skip to content

Commit 9ff446c

Browse files
committed
fixed codes, added save delete and create tasks and notes
1 parent 4eca043 commit 9ff446c

9 files changed

Lines changed: 733 additions & 579 deletions

File tree

src/lib/features/auth/viewmodels/task_provider.dart

Whitespace-only changes.

src/lib/features/main/view/screens/task.dart

Lines changed: 0 additions & 322 deletions
This file was deleted.

src/lib/features/tasks/model/task_model.dart

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,3 +77,23 @@ class TaskModel {
7777
this.tags = const [],
7878
});
7979
}
80+
81+
class NoteModel {
82+
final int id;
83+
final String content;
84+
final bool pinned;
85+
86+
NoteModel({
87+
required this.id,
88+
required this.content,
89+
this.pinned = false,
90+
});
91+
92+
factory NoteModel.fromJson(Map<String, dynamic> json) {
93+
return NoteModel(
94+
id: json['id'],
95+
content: json['content'] ?? '',
96+
pinned: json['pinned'] ?? false,
97+
);
98+
}
99+
}

0 commit comments

Comments
 (0)