Skip to content

Commit

Permalink
fixes allowing of past dates
Browse files Browse the repository at this point in the history
  • Loading branch information
vkprogrammer-001 committed Jan 24, 2024
1 parent a3beb7a commit 10bb650
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/widgets/taskdetails/dateTimePicker.dart
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class DateTimeWidget extends StatelessWidget {
var date = await showDatePicker(
context: context,
initialDate: initialDate,
firstDate: DateTime(1990), // >= 1980-01-01T00:00:00.000Z
firstDate: DateTime.now(), // sets the earliest selectable date to the current date. This prevents the user from selecting a date in the past.
lastDate: DateTime(2037, 12, 31), // < 2038-01-19T03:14:08.000Z
);
if (date != null) {
Expand Down

0 comments on commit 10bb650

Please sign in to comment.