@ -46,6 +46,10 @@ class _PatientSearchScreenState extends State<PatientSearchScreen> {
bool isFormSubmitted = false ;
bool isFormSubmitted = false ;
FocusNode _nodeText1 = FocusNode ( ) ;
FocusNode _nodeText2 = FocusNode ( ) ;
FocusNode _nodeText3 = FocusNode ( ) ;
var _patientSearchFormValues = PatientModel (
var _patientSearchFormValues = PatientModel (
FirstName: " 0 " ,
FirstName: " 0 " ,
MiddleName: " 0 " ,
MiddleName: " 0 " ,
@ -110,7 +114,11 @@ class _PatientSearchScreenState extends State<PatientSearchScreen> {
@ override
@ override
Widget build ( BuildContext context ) {
Widget build ( BuildContext context ) {
projectsProvider = Provider . of ( context ) ;
projectsProvider = Provider . of ( context ) ;
return AppScaffold (
return GestureDetector (
onTap: ( ) {
FocusScope . of ( context ) . requestFocus ( new FocusNode ( ) ) ;
} ,
child: AppScaffold (
appBarTitle: TranslationBase . of ( context ) . searchPatient ,
appBarTitle: TranslationBase . of ( context ) . searchPatient ,
body: ListView (
body: ListView (
children: < Widget > [
children: < Widget > [
@ -344,7 +352,9 @@ class _PatientSearchScreenState extends State<PatientSearchScreen> {
TranslationBase . of ( context ) . phoneNumber ,
TranslationBase . of ( context ) . phoneNumber ,
borderColor: Colors . white ,
borderColor: Colors . white ,
textInputType: TextInputType . number ,
textInputType: TextInputType . number ,
textInputAction: TextInputAction . done ,
inputFormatter: ONLY_NUMBERS ,
inputFormatter: ONLY_NUMBERS ,
focusNode: _nodeText1 ,
onSaved: ( value ) {
onSaved: ( value ) {
value = = null | | value = = ' '
value = = null | | value = = ' '
? _patientSearchFormValues
? _patientSearchFormValues
@ -378,6 +388,7 @@ class _PatientSearchScreenState extends State<PatientSearchScreen> {
borderColor: Colors . white ,
borderColor: Colors . white ,
textInputType: TextInputType . number ,
textInputType: TextInputType . number ,
inputFormatter: ONLY_NUMBERS ,
inputFormatter: ONLY_NUMBERS ,
focusNode: _nodeText2 ,
onSaved: ( value ) {
onSaved: ( value ) {
value = = null | | value = = ' '
value = = null | | value = = ' '
? _patientSearchFormValues . setPatientID =
? _patientSearchFormValues . setPatientID =
@ -407,6 +418,7 @@ class _PatientSearchScreenState extends State<PatientSearchScreen> {
TranslationBase . of ( context ) . patientFile ,
TranslationBase . of ( context ) . patientFile ,
borderColor: Colors . white ,
borderColor: Colors . white ,
textInputType: TextInputType . number ,
textInputType: TextInputType . number ,
focusNode: _nodeText3 ,
inputFormatter: ONLY_NUMBERS ,
inputFormatter: ONLY_NUMBERS ,
onSaved: ( value ) { } ,
onSaved: ( value ) { } ,
) ,
) ,
@ -478,6 +490,7 @@ class _PatientSearchScreenState extends State<PatientSearchScreen> {
) ,
) ,
) ,
) ,
] ,
] ,
) ) ;
) ) ,
) ;
}
}
}
}