merge-requests/104/head
Mohammad ALjammal 6 years ago
commit 3495e6bc9b

@ -23,6 +23,7 @@ Helpers helpers = Helpers();
class LoginForm extends StatefulWidget with DrAppToastMsg {
LoginForm({this.changeLoadingStata});
final Function changeLoadingStata;
@override
@ -85,7 +86,7 @@ class _LoginFormState extends State<LoginForm> {
return null;
},
onSaved: (value) {
userInfo.UserID = value;
userInfo.UserID = value.trim();
},
onFieldSubmitted: (_) {
FocusScope.of(context).requestFocus(focusPass);
@ -184,9 +185,9 @@ class _LoginFormState extends State<LoginForm> {
);
}
/*
*@author: Elham Rababah
*@Date:20/4/2020
/*
*@author: Elham Rababah
*@Date:20/4/2020
*@param: context, hint, asset
*@return: InputDecoration
*@desc: decorate input feilds
@ -337,6 +338,7 @@ class _LoginFormState extends State<LoginForm> {
userInfo.ProjectID = projectsList[index]["ID"];
projectIdController.text = projectsList[index]['Name'];
});
FocusScope.of(context).requestFocus(focusProject);
primaryFocus.unfocus();
}
}

@ -21,7 +21,9 @@ Helpers helpers = Helpers();
class VerifyAccount extends StatefulWidget {
VerifyAccount({this.changeLoadingStata});
final Function changeLoadingStata;
@override
_VerifyAccountState createState() => _VerifyAccountState();
}
@ -37,8 +39,9 @@ class _VerifyAccountState extends State<VerifyAccount> {
Future _loggedUserFuture;
var _loggedUser;
AuthProvider authProv;
bool _isInit =true;
bool _isInit = true;
var model;
@override
void initState() {
super.initState();
@ -93,25 +96,30 @@ class _VerifyAccountState extends State<VerifyAccount> {
MainAxisAlignment.spaceAround,
children: <Widget>[
Container(
width: SizeConfig.realScreenWidth * 0.20,
child: TextFormField(
textInputAction: TextInputAction.next,
style: buildTextStyle(),
maxLength: 1,
textAlign: TextAlign.center,
keyboardType: TextInputType.number,
decoration:
buildInputDecoration(context),
onSaved: (val) {
verifyAccountFormValue['digit1'] =
val;
},
validator: validateCodeDigit,
onFieldSubmitted: (_) {
width: SizeConfig.realScreenWidth * 0.20,
child: TextFormField(
textInputAction: TextInputAction.next,
style: buildTextStyle(),
maxLength: 1,
textAlign: TextAlign.center,
keyboardType: TextInputType.number,
decoration: buildInputDecoration(context),
onSaved: (val) {
verifyAccountFormValue['digit1'] = val;
},
validator: validateCodeDigit,
onFieldSubmitted: (_) {
FocusScope.of(context)
.requestFocus(focusD2);
},
onChanged: (val) {
if (val.length == 1) {
FocusScope.of(context)
.requestFocus(focusD2);
},
)),
}
},
),
),
Container(
width: SizeConfig.realScreenWidth * 0.20,
child: TextFormField(
@ -131,6 +139,12 @@ class _VerifyAccountState extends State<VerifyAccount> {
FocusScope.of(context)
.requestFocus(focusD3);
},
onChanged: (val) {
if (val.length == 1) {
FocusScope.of(context)
.requestFocus(focusD3);
}
},
validator: validateCodeDigit),
),
Container(
@ -152,6 +166,12 @@ class _VerifyAccountState extends State<VerifyAccount> {
FocusScope.of(context)
.requestFocus(focusD4);
},
onChanged: (val) {
if (val.length == 1) {
FocusScope.of(context)
.requestFocus(focusD4);
}
},
validator: validateCodeDigit)),
Container(
width: SizeConfig.realScreenWidth * 0.20,
@ -214,10 +234,10 @@ class _VerifyAccountState extends State<VerifyAccount> {
});
}
/*
*@author: Elham Rababah
*@Date:19/4/2020
*@param:
/*
*@author: Elham Rababah
*@Date:19/4/2020
*@param:
*@return:
*@desc: change the style for the input field
*/
@ -234,9 +254,9 @@ class _VerifyAccountState extends State<VerifyAccount> {
return null;
}
/*
*@author: Elham Rababah
*@Date:28/4/2020
/*
*@author: Elham Rababah
*@Date:28/4/2020
*@param: context
*@return:InputDecoration
*@desc: buildInputDecoration
@ -255,10 +275,10 @@ class _VerifyAccountState extends State<VerifyAccount> {
));
}
/*
*@author: Elham Rababah
*@Date:28/4/2020
*@param:
/*
*@author: Elham Rababah
*@Date:28/4/2020
*@param:
*@return: RichText
*@desc: buildText
*/
@ -283,9 +303,9 @@ class _VerifyAccountState extends State<VerifyAccount> {
);
}
/*
*@author: Elham Rababah
*@Date:15/4/2020
/*
*@author: Elham Rababah
*@Date:15/4/2020
*@param: authProv
*@return:
*@desc: verify Account func call sendActivationCodeByOtpNotificationType service
@ -349,8 +369,8 @@ class _VerifyAccountState extends State<VerifyAccount> {
}
}
/*
*@author: Elham Rababah
/*
*@author: Elham Rababah
*@Date:17/5/2020
*@param: Map<String, dynamic> profile, Function changeLoadingStata
*@return:
@ -385,7 +405,7 @@ class _VerifyAccountState extends State<VerifyAccount> {
});
}
/*
/*
*@author: Elham Rababah
*@Date:17/5/2020
*@param: ClinicModel clinicInfo, Function changeLoadingStata

Loading…
Cancel
Save