|
|
|
@ -161,7 +161,7 @@ class ApiClientImp implements ApiClient {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
body['LanguageID'] = body['LanguageID'] ?? "1";
|
|
|
|
body['LanguageID'] = body['LanguageID'] ?? "2";
|
|
|
|
body['VersionID'] = body['VersionID'] ?? "18.7";
|
|
|
|
body['VersionID'] = body['VersionID'] ?? "18.7";
|
|
|
|
body['Channel'] = body['Channel'] ?? "3";
|
|
|
|
body['Channel'] = body['Channel'] ?? "3";
|
|
|
|
body['IPAdress'] = body['IPAdress'] ?? "10.20.10.20";
|
|
|
|
body['IPAdress'] = body['IPAdress'] ?? "10.20.10.20";
|
|
|
|
@ -169,6 +169,8 @@ class ApiClientImp implements ApiClient {
|
|
|
|
body['Latitude'] = body['Latitude'] ?? "0.0";
|
|
|
|
body['Latitude'] = body['Latitude'] ?? "0.0";
|
|
|
|
body['Longitude'] = body['Longitude'] ?? "0.0";
|
|
|
|
body['Longitude'] = body['Longitude'] ?? "0.0";
|
|
|
|
body['DeviceTypeID'] = body['DeviceTypeID'] ??
|
|
|
|
body['DeviceTypeID'] = body['DeviceTypeID'] ??
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(Platform.isIOS ? "1" : await Utils.isGoogleServicesAvailable() ? "2" : "3");
|
|
|
|
(Platform.isIOS ? "1" : await Utils.isGoogleServicesAvailable() ? "2" : "3");
|
|
|
|
//"LanguageID":1,"VersionID":18.7,"Channel":3,"IPAdress":"10.20.10.20","generalid":"Cs2020@2016$2958","Latitude":0.0,"Longitude":0.0,"DeviceTypeID":2,"PatientType":1}
|
|
|
|
//"LanguageID":1,"VersionID":18.7,"Channel":3,"IPAdress":"10.20.10.20","generalid":"Cs2020@2016$2958","Latitude":0.0,"Longitude":0.0,"DeviceTypeID":2,"PatientType":1}
|
|
|
|
body.removeWhere((key, value) => value == null);
|
|
|
|
body.removeWhere((key, value) => value == null);
|
|
|
|
@ -186,7 +188,6 @@ class ApiClientImp implements ApiClient {
|
|
|
|
logApiEndpointError(endPoint, 'Error While Fetching data', statusCode);
|
|
|
|
logApiEndpointError(endPoint, 'Error While Fetching data', statusCode);
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
var parsed = json.decode(utf8.decode(response.bodyBytes));
|
|
|
|
var parsed = json.decode(utf8.decode(response.bodyBytes));
|
|
|
|
|
|
|
|
|
|
|
|
log("parsed: ${parsed.toString()}");
|
|
|
|
log("parsed: ${parsed.toString()}");
|
|
|
|
if (isAllowAny) {
|
|
|
|
if (isAllowAny) {
|
|
|
|
onSuccess(parsed, statusCode);
|
|
|
|
onSuccess(parsed, statusCode);
|
|
|
|
|