From 3f0c60aea568a1eeb2661f4e6f84d868adf8d726 Mon Sep 17 00:00:00 2001 From: Sultan Khan Date: Wed, 12 Aug 2020 10:53:50 +0300 Subject: [PATCH] sessionID --- lib/core/service/client/base_app_client.dart | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/core/service/client/base_app_client.dart b/lib/core/service/client/base_app_client.dart index 6a6fb0ce..05cb0f8b 100644 --- a/lib/core/service/client/base_app_client.dart +++ b/lib/core/service/client/base_app_client.dart @@ -32,7 +32,7 @@ class BaseAppClient { body['IPAdress'] = IP_ADDRESS; body['generalid'] = GENERAL_ID; // body['PatientOutSA'] = PATIENT_OUT_SA; - body['SessionID'] = SESSION_ID; + body['SessionID'] = null; //SESSION_ID; body['isDentalAllowedBackend'] = IS_DENTAL_ALLOWED_BACKEND; body['DeviceTypeID'] = DeviceTypeID; body['PatientType'] = PATIENT_TYPE; @@ -41,6 +41,7 @@ class BaseAppClient { body['TokenID'] = token; //user['TokenID']; body['PatientID'] = user['PatientID']; body['PatientOutSA'] = user['OutSA']; + body['SessionID'] = getSessionId(token); } print("URL : $url"); @@ -90,4 +91,8 @@ class BaseAppClient { logout() async { await sharedPref.remove(LOGIN_TOKEN_ID); } + + String getSessionId(String id) { + return id.replaceAll('/[^a-zA-Z ]', ''); + } }