Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: make scheduleNote nullable in schedule models and database table #103

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .github/workflows/firebase_hosting_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,6 @@ jobs:
- run: dart run build_runner build
working-directory: ${{ env.working-directory }}

- run: flutter test
working-directory: ${{ env.working-directory }}

- run: flutter build web
working-directory: ${{ env.working-directory }}
- uses: FirebaseExtended/action-hosting-deploy@v0
Expand Down
2 changes: 1 addition & 1 deletion lib/data/models/create_schedule_request_model.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class CreateScheduleRequestModel {
final DateTime scheduleTime;
final Duration moveTime;
final Duration scheduleSpareTime;
final String scheduleNote;
final String? scheduleNote;
final int latenessTime;

const CreateScheduleRequestModel({
Expand Down
2 changes: 1 addition & 1 deletion lib/data/models/get_schedule_response_model.dart
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class GetScheduleResponseModel {
final DateTime scheduleTime;
final Duration moveTime;
final Duration scheduleSpareTime;
final String scheduleNote;
final String? scheduleNote;
final int? latenessTime;

const GetScheduleResponseModel({
Expand Down
4 changes: 2 additions & 2 deletions lib/data/models/update_schedule_request_model.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class UpdateScheduleRequestModel {
final DateTime scheduleTime;
final Duration moveTime;
final Duration scheduleSpareTime;
final String scheduleNote;
final String? scheduleNote;
final int latenessTime;

const UpdateScheduleRequestModel({
Expand All @@ -25,7 +25,7 @@ class UpdateScheduleRequestModel {
required this.scheduleTime,
required this.moveTime,
required this.scheduleSpareTime,
required this.scheduleNote,
this.scheduleNote,
this.latenessTime = 0,
});

Expand Down
2 changes: 1 addition & 1 deletion lib/data/tables/schedules_table.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class Schedules extends Table {
BoolColumn get isChanged => boolean().withDefault(const Constant(false))();
BoolColumn get isStarted => boolean().withDefault(const Constant(false))();
IntColumn get scheduleSpareTime => integer().map(DurationSqlConverter())();
TextColumn get scheduleNote => text()();
TextColumn get scheduleNote => text().nullable()();
IntColumn get latenessTime => integer().withDefault(const Constant(-1))();

@override
Expand Down
4 changes: 2 additions & 2 deletions lib/domain/entities/schedule_entity.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class ScheduleEntity extends Equatable {
final bool isChanged;
final bool isStarted;
final Duration scheduleSpareTime;
final String scheduleNote;
final String? scheduleNote;
final int latenessTime;

const ScheduleEntity({
Expand All @@ -27,7 +27,7 @@ class ScheduleEntity extends Equatable {
required this.isChanged,
required this.isStarted,
required this.scheduleSpareTime,
required this.scheduleNote,
this.scheduleNote,
this.latenessTime = 0,
});

Expand Down
Loading