|
|
|
@ -52,7 +52,7 @@ class LoginApiClient {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Future<CheckMobileAppVersionModel> checkMobileAppVersion() async {
|
|
|
|
Future<CheckMobileAppVersionModel> checkMobileAppVersion() async {
|
|
|
|
String url = "${ApiConsts.utilitiesRest}CheckMobileAppVersion"; // todo @zahoor, not found in swagger
|
|
|
|
String url = "${ApiConsts.authRest}CheckMobileAppVersion";
|
|
|
|
Map<String, dynamic> postParams = {};
|
|
|
|
Map<String, dynamic> postParams = {};
|
|
|
|
postParams.addAll(AppState().postParamsJson);
|
|
|
|
postParams.addAll(AppState().postParamsJson);
|
|
|
|
return await ApiClient().postJsonForObject((json) => CheckMobileAppVersionModel.fromJson(json), url, postParams);
|
|
|
|
return await ApiClient().postJsonForObject((json) => CheckMobileAppVersionModel.fromJson(json), url, postParams);
|
|
|
|
@ -65,6 +65,7 @@ class LoginApiClient {
|
|
|
|
return await ApiClient().postJsonForObject((json) {
|
|
|
|
return await ApiClient().postJsonForObject((json) {
|
|
|
|
GenericResponseModel responseData = GenericResponseModel.fromJson(json);
|
|
|
|
GenericResponseModel responseData = GenericResponseModel.fromJson(json);
|
|
|
|
AppState().postParamsObject?.setLogInTokenID = responseData.logInTokenID;
|
|
|
|
AppState().postParamsObject?.setLogInTokenID = responseData.logInTokenID;
|
|
|
|
|
|
|
|
print("setLogInTokenID:${AppState().postParamsObject?.logInTokenID}");
|
|
|
|
return responseData.memberLoginList;
|
|
|
|
return responseData.memberLoginList;
|
|
|
|
}, url, postParams);
|
|
|
|
}, url, postParams);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
@ -73,12 +74,19 @@ class LoginApiClient {
|
|
|
|
String url = "${ApiConsts.authRest}Mohemm_SendActivationCodebyOTPNotificationType";
|
|
|
|
String url = "${ApiConsts.authRest}Mohemm_SendActivationCodebyOTPNotificationType";
|
|
|
|
Map<String, dynamic> postParams = {"IsMobileFingerPrint": isMobileFingerPrint, "MobileNumber": mobileNumber, "OTP_SendType": optSendType, "P_USER_NAME": pUserName};
|
|
|
|
Map<String, dynamic> postParams = {"IsMobileFingerPrint": isMobileFingerPrint, "MobileNumber": mobileNumber, "OTP_SendType": optSendType, "P_USER_NAME": pUserName};
|
|
|
|
postParams.addAll(AppState().postParamsJson);
|
|
|
|
postParams.addAll(AppState().postParamsJson);
|
|
|
|
return await ApiClient().postJsonForObject((json) => GenericResponseModel.fromJson(json).basicMemberInformation, url, postParams);
|
|
|
|
postParams["LogInTokenID"]=AppState().postParamsObject?.logInTokenID;
|
|
|
|
|
|
|
|
print(postParams);
|
|
|
|
|
|
|
|
return await ApiClient().postJsonForObject((json) {
|
|
|
|
|
|
|
|
AppState().postParamsObject?.setLogInTokenID = json["LogInTokenID"];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return BasicMemberInformationModel.fromJson(json);
|
|
|
|
|
|
|
|
// GenericResponseModel.fromJson(json).basicMemberInformation;
|
|
|
|
|
|
|
|
}, url, postParams);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Future<GenericResponseModel?> checkActivationCode(bool isDeviceNFC, String? mobileNumber, String activationCode, String? pUserName) async {
|
|
|
|
Future<GenericResponseModel?> checkActivationCode(bool isDeviceNFC, String? mobileNumber, String activationCode, String? pUserName) async {
|
|
|
|
String url = "${ApiConsts.authRest}CheckActivationCode";
|
|
|
|
String url = "${ApiConsts.authRest}CheckActivationCode";
|
|
|
|
Map<String, dynamic> postParams = {"IsDeviceNFC": isDeviceNFC, "MobileNumber": mobileNumber, "activationCode": activationCode, "P_USER_NAME": pUserName};
|
|
|
|
Map<String, dynamic> postParams = {"IsDeviceNFC": isDeviceNFC, "MobileNumber": mobileNumber, "ActivationCode": activationCode, "P_USER_NAME": pUserName};
|
|
|
|
postParams.addAll(AppState().postParamsJson);
|
|
|
|
postParams.addAll(AppState().postParamsJson);
|
|
|
|
return await ApiClient().postJsonForObject((json) {
|
|
|
|
return await ApiClient().postJsonForObject((json) {
|
|
|
|
GenericResponseModel responseData = GenericResponseModel.fromJson(json);
|
|
|
|
GenericResponseModel responseData = GenericResponseModel.fromJson(json);
|
|
|
|
|