validAdharCard static method

String? validAdharCard({
  1. String? value,
})

Implementation

static String? validAdharCard({String? value}) {
  if (value!.isEmpty) {
    return 'Please Enter your Adhaar Card Number';
  } else if (value.trim().length != 12) {
    return 'Please Enter valid Adhaar Card Number';
  } else if (!value.isNumericOnly) {
    return 'Please Enter valid Adhaar Card Number';
  }
  return null;
}