|
|
|
@ -142,7 +142,7 @@ class AuthenticationViewModel extends BaseViewModel {
|
|
|
|
|
iMEI: user.iMEI,
|
|
|
|
|
facilityId: user.projectID,
|
|
|
|
|
memberID: user.doctorID,
|
|
|
|
|
loginDoctorID: user.doctorID,
|
|
|
|
|
loginDoctorID: int.parse(user.editedBy.toString()),
|
|
|
|
|
zipCode: user.outSA == true ? '971' : '966',
|
|
|
|
|
mobileNumber: user.mobile,
|
|
|
|
|
oTPSendType: authMethodType.getTypeIdService(),
|
|
|
|
@ -172,7 +172,7 @@ class AuthenticationViewModel extends BaseViewModel {
|
|
|
|
|
error = _authService.error;
|
|
|
|
|
setState(ViewState.ErrorLocal);
|
|
|
|
|
} else {
|
|
|
|
|
await sharedPref.setString(LOGIN_TOKEN_ID,
|
|
|
|
|
await sharedPref.setString(TOKEN,
|
|
|
|
|
_authService.activationCodeForDoctorAppRes.logInTokenID);
|
|
|
|
|
setState(ViewState.Idle);
|
|
|
|
|
}
|
|
|
|
@ -191,14 +191,14 @@ class AuthenticationViewModel extends BaseViewModel {
|
|
|
|
|
projectID: await sharedPref.getInt(PROJECT_ID) != null
|
|
|
|
|
? await sharedPref.getInt(PROJECT_ID)
|
|
|
|
|
: user.projectID,
|
|
|
|
|
logInTokenID: await sharedPref.getString(LOGIN_TOKEN_ID),
|
|
|
|
|
logInTokenID: await sharedPref.getString(TOKEN),
|
|
|
|
|
activationCode: activationCode ?? '0000',
|
|
|
|
|
memberID:userInfo.userID!=null? int.parse(userInfo.userID):user.doctorID ,
|
|
|
|
|
password: userInfo.password,
|
|
|
|
|
facilityId:userInfo.projectID!=null? userInfo.projectID.toString():user.projectID.toString(),
|
|
|
|
|
oTPSendType: await sharedPref.getInt(OTP_TYPE),
|
|
|
|
|
iMEI: localToken,
|
|
|
|
|
loginDoctorID:userInfo.userID!=null? int.parse(userInfo.userID):user.doctorID,// loggedUser.listMemberInformation[0].employeeID,
|
|
|
|
|
loginDoctorID:userInfo.userID!=null? int.parse(userInfo.userID):user.editedBy,// loggedUser.listMemberInformation[0].employeeID,
|
|
|
|
|
isForSilentLogin:isSilentLogin,
|
|
|
|
|
generalid: "Cs2020@2016\$2958");
|
|
|
|
|
await _authService.checkActivationCodeForDoctorApp(checkActivationCodeForDoctorApp);
|
|
|
|
@ -258,7 +258,7 @@ class AuthenticationViewModel extends BaseViewModel {
|
|
|
|
|
sendActivationCodeForDoctorAppResponseModel.vidaAuthTokenID);
|
|
|
|
|
await sharedPref.setString(VIDA_REFRESH_TOKEN_ID,
|
|
|
|
|
sendActivationCodeForDoctorAppResponseModel.vidaRefreshTokenID);
|
|
|
|
|
await sharedPref.setString(LOGIN_TOKEN_ID,
|
|
|
|
|
await sharedPref.setString(TOKEN,
|
|
|
|
|
sendActivationCodeForDoctorAppResponseModel.authenticationTokenID);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|