isValid method

  1. @override
bool isValid()
override

Implementation

@override
bool isValid() {
  if (!(model.required ?? false)) {
    return true;
  } else {
    if (model.calendarType == GSCalendarType.jalali) {
      return selectedJalaliDate != null;
    } else {
      return selectedGregorianDate != null;
    }
  }
}