-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
reorganize project structure a little bit
- Loading branch information
Showing
6 changed files
with
21 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import 'package:drift/drift.dart'; | ||
import 'package:timetable/constants/days.dart'; | ||
import 'package:timetable/constants/rotation_weeks.dart'; | ||
import 'package:timetable/db/converters/time_of_day_converter.dart'; | ||
|
||
class Subject extends Table { | ||
IntColumn get id => integer().autoIncrement()(); | ||
TextColumn get label => text()(); | ||
TextColumn get location => text().nullable()(); | ||
TextColumn get note => text().nullable()(); | ||
IntColumn get color => integer()(); | ||
IntColumn get rotationWeek => intEnum<RotationWeeks>()(); | ||
IntColumn get day => intEnum<Days>()(); | ||
TextColumn get startTime => text().map(const TimeOfDayConverter())(); | ||
TextColumn get endTime => text().map(const TimeOfDayConverter())(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters