Compare commits

...

3 Commits

@ -102,6 +102,9 @@ android {
sourceCompatibility JavaVersion.VERSION_17 sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17 targetCompatibility JavaVersion.VERSION_17
} }
kotlinOptions {
jvmTarget = '17'
}
} }

@ -1,69 +1,69 @@
package com.hmg.hmgDr.Service; //package com.hmg.hmgDr.Service;
//
import android.app.Activity; //import android.app.Activity;
import android.app.Application; //import android.app.Application;
//
import androidx.annotation.CallSuper; //import androidx.annotation.CallSuper;
//
import com.google.gson.Gson; //import com.google.gson.Gson;
import com.google.gson.GsonBuilder; //import com.google.gson.GsonBuilder;
//
import java.util.concurrent.TimeUnit; //import java.util.concurrent.TimeUnit;
//
import io.flutter.view.FlutterMain; //import io.flutter.view.FlutterMain;
import okhttp3.ConnectionPool; //import okhttp3.ConnectionPool;
import okhttp3.OkHttpClient; //import okhttp3.OkHttpClient;
import okhttp3.logging.HttpLoggingInterceptor; //import okhttp3.logging.HttpLoggingInterceptor;
import retrofit2.Retrofit; //import retrofit2.Retrofit;
import retrofit2.converter.gson.GsonConverterFactory; //import retrofit2.converter.gson.GsonConverterFactory;
//
public class AppRetrofit extends Application { //public class AppRetrofit extends Application {
private static final int MY_SOCKET_TIMEOUT_MS = 20000; // private static final int MY_SOCKET_TIMEOUT_MS = 20000;
//
@Override // @Override
@CallSuper // @CallSuper
public void onCreate() { // public void onCreate() {
super.onCreate(); // super.onCreate();
FlutterMain.startInitialization(this); // FlutterMain.startInitialization(this);
} // }
//
private Activity mCurrentActivity = null; // private Activity mCurrentActivity = null;
//
public Activity getCurrentActivity() { // public Activity getCurrentActivity() {
return mCurrentActivity; // return mCurrentActivity;
} // }
//
public void setCurrentActivity(Activity mCurrentActivity) { // public void setCurrentActivity(Activity mCurrentActivity) {
this.mCurrentActivity = mCurrentActivity; // this.mCurrentActivity = mCurrentActivity;
} // }
//
public static Retrofit getRetrofit( String baseUrl) { // public static Retrofit getRetrofit( String baseUrl) {
//
HttpLoggingInterceptor interceptor = new HttpLoggingInterceptor(); // HttpLoggingInterceptor interceptor = new HttpLoggingInterceptor();
interceptor.setLevel(HttpLoggingInterceptor.Level.BODY); // interceptor.setLevel(HttpLoggingInterceptor.Level.BODY);
Gson gson = new GsonBuilder().serializeNulls().create(); // Gson gson = new GsonBuilder().serializeNulls().create();
OkHttpClient okHttpClient = new OkHttpClient.Builder().addInterceptor(chain -> { // OkHttpClient okHttpClient = new OkHttpClient.Builder().addInterceptor(chain -> {
okhttp3.Request originalRequest = chain.request(); // okhttp3.Request originalRequest = chain.request();
okhttp3.Request newRequest = originalRequest.newBuilder() // okhttp3.Request newRequest = originalRequest.newBuilder()
.addHeader("Content-Type","application/json") // .addHeader("Content-Type","application/json")
.addHeader("Accept","application/json") // .addHeader("Accept","application/json")
.build(); // .build();
//
return chain.proceed(newRequest); // return chain.proceed(newRequest);
}) // })
.addInterceptor(interceptor) // .addInterceptor(interceptor)
.callTimeout(MY_SOCKET_TIMEOUT_MS, TimeUnit.SECONDS) // .callTimeout(MY_SOCKET_TIMEOUT_MS, TimeUnit.SECONDS)
.connectTimeout(MY_SOCKET_TIMEOUT_MS, TimeUnit.SECONDS) // .connectTimeout(MY_SOCKET_TIMEOUT_MS, TimeUnit.SECONDS)
.readTimeout(MY_SOCKET_TIMEOUT_MS, TimeUnit.SECONDS) // .readTimeout(MY_SOCKET_TIMEOUT_MS, TimeUnit.SECONDS)
.connectionPool(new ConnectionPool(0, 5 * 60 * 1000, TimeUnit.SECONDS)) // .connectionPool(new ConnectionPool(0, 5 * 60 * 1000, TimeUnit.SECONDS))
.retryOnConnectionFailure(false) // .retryOnConnectionFailure(false)
.build(); // .build();
//
//
return new Retrofit.Builder() // return new Retrofit.Builder()
.baseUrl(baseUrl) // .baseUrl(baseUrl)
.addConverterFactory(GsonConverterFactory.create(gson)) // .addConverterFactory(GsonConverterFactory.create(gson))
.client(okHttpClient) // .client(okHttpClient)
.build(); // .build();
} // }
} //}

@ -3,7 +3,7 @@ package com.hmg.hmgDr.ui;
import com.hmg.hmgDr.Model.ChangeCallStatusRequestModel; import com.hmg.hmgDr.Model.ChangeCallStatusRequestModel;
import com.hmg.hmgDr.Model.GetSessionStatusModel; import com.hmg.hmgDr.Model.GetSessionStatusModel;
import com.hmg.hmgDr.Model.SessionStatusModel; import com.hmg.hmgDr.Model.SessionStatusModel;
import com.hmg.hmgDr.Service.AppRetrofit; //import com.hmg.hmgDr.Service.AppRetrofit;
import com.hmg.hmgDr.Service.SessionStatusAPI; import com.hmg.hmgDr.Service.SessionStatusAPI;
import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.NotNull;
@ -27,7 +27,7 @@ public class VideoCallPresenterImpl implements VideoCallContract.VideoCallPresen
public void callClintConnected(GetSessionStatusModel statusModel) { public void callClintConnected(GetSessionStatusModel statusModel) {
sessionStatusAPI = AppRetrofit.getRetrofit(baseUrl).create(SessionStatusAPI.class); // sessionStatusAPI = AppRetrofit.getRetrofit(baseUrl).create(SessionStatusAPI.class);
Call<SessionStatusModel> call = sessionStatusAPI.getSessionStatusModelData(statusModel); Call<SessionStatusModel> call = sessionStatusAPI.getSessionStatusModelData(statusModel);
@ -50,7 +50,7 @@ public class VideoCallPresenterImpl implements VideoCallContract.VideoCallPresen
@Override @Override
public void callChangeCallStatus(ChangeCallStatusRequestModel statusModel) { public void callChangeCallStatus(ChangeCallStatusRequestModel statusModel) {
sessionStatusAPI = AppRetrofit.getRetrofit(baseUrl).create(SessionStatusAPI.class); // sessionStatusAPI = AppRetrofit.getRetrofit(baseUrl).create(SessionStatusAPI.class);
Call<SessionStatusModel> call = sessionStatusAPI.changeCallStatus(statusModel); Call<SessionStatusModel> call = sessionStatusAPI.changeCallStatus(statusModel);

@ -3,3 +3,4 @@
android.useAndroidX=true android.useAndroidX=true
android.enableJetifier=true android.enableJetifier=true
org.gradle.jvmargs=-Xmx4608m org.gradle.jvmargs=-Xmx4608m
kotlin.jvm.target.validation.mode = IGNORE

@ -35,16 +35,49 @@ target 'Runner' do
pod 'OpenTok' pod 'OpenTok'
pod 'Alamofire', '~> 5.2' pod 'Alamofire', '~> 5.2'
pod 'AADraggableView' pod 'AADraggableView'
# pod 'Firebase', '~> 11.11.0'
# Plugin Pods # Plugin Pods
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
pod 'DKImagePickerController/PhotoGallery', :git => 'https://github.com/miguelpruivo/DKImagePickerController.git' pod 'DKImagePickerController/PhotoGallery', :git => 'https://github.com/miguelpruivo/DKImagePickerController.git'
end end
# $deployment_target = '13.0'
# pre_install do |installer|
# installer.pod_targets.each do |pod|
# pod.platform = :ios, $deployment_target
# end
# end
# post_install do |installer|
# installer.pods_project.targets.each do |target|
# target.build_configurations.each do |config|
# config.build_settings['CLANG_CXX_LANGUAGE_STANDARD'] = 'c++17'
# config.build_settings['CLANG_CXX_LIBRARY'] = 'libc++'
# config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '13.0'
# config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64' # For Apple Silicon
# end
# flutter_additional_ios_build_settings(target)
# end
# end
post_install do |installer| post_install do |installer|
installer.pods_project.targets.each do |target| installer.pods_project.targets.each do |target|
if target.name == 'BoringSSL-GRPC'
target.source_build_phase.files.each do |file|
if file.settings && file.settings['COMPILER_FLAGS']
flags = file.settings['COMPILER_FLAGS'].split
flags.reject! { |flag| flag == '-GCC_WARN_INHIBIT_ALL_WARNINGS' }
file.settings['COMPILER_FLAGS'] = flags.join(' ')
end
end
end
flutter_additional_ios_build_settings(target) flutter_additional_ios_build_settings(target)
target.build_configurations.each do |build_configuration| target.build_configurations.each do |build_configuration|
build_configuration.build_settings['CLANG_CXX_LANGUAGE_STANDARD'] = 'c++17'
build_configuration.build_settings['CLANG_CXX_LIBRARY'] = 'libc++'
build_configuration.build_settings['OTHER_CPLUSPLUSFLAGS'] = '-std=c++17'
build_configuration.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [ build_configuration.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [
'$(inherited)', '$(inherited)',
## dart: [PermissionGroup.location, PermissionGroup.locationAlways, PermissionGroup.locationWhenInUse] ## dart: [PermissionGroup.location, PermissionGroup.locationAlways, PermissionGroup.locationWhenInUse]
@ -56,6 +89,8 @@ post_install do |installer|
if build_configuration.build_settings['WRAPPER_EXTENSION'] == 'bundle' if build_configuration.build_settings['WRAPPER_EXTENSION'] == 'bundle'
build_configuration.build_settings['DEVELOPMENT_TEAM'] = '3A359E86ZF' build_configuration.build_settings['DEVELOPMENT_TEAM'] = '3A359E86ZF'
end end
build_configuration.build_settings['CLANG_CXX_LANGUAGE_STANDARD'] = 'c++17' # or 'c++17'
build_configuration.build_settings['CLANG_CXX_LIBRARY'] = 'libc++'
end end
end end
end end

@ -2,6 +2,8 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CADisableMinimumFrameDurationOnPhone</key>
<true/>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string> <string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleDisplayName</key> <key>CFBundleDisplayName</key>
@ -46,6 +48,13 @@
<string>Need to upload image</string> <string>Need to upload image</string>
<key>NSSpeechRecognitionUsageDescription</key> <key>NSSpeechRecognitionUsageDescription</key>
<string>This permission is not needed by the app, but it is required by an underlying API. If you see this dialog, contact us.</string> <string>This permission is not needed by the app, but it is required by an underlying API. If you see this dialog, contact us.</string>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
<key>UIBackgroundModes</key>
<array>
<string>remote-notification</string>
<string>fetch</string>
</array>
<key>UILaunchStoryboardName</key> <key>UILaunchStoryboardName</key>
<string>LaunchScreen</string> <string>LaunchScreen</string>
<key>UIMainStoryboardFile</key> <key>UIMainStoryboardFile</key>
@ -65,9 +74,5 @@
</array> </array>
<key>UIViewControllerBasedStatusBarAppearance</key> <key>UIViewControllerBasedStatusBarAppearance</key>
<false/> <false/>
<key>CADisableMinimumFrameDurationOnPhone</key>
<true/>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
</dict> </dict>
</plist> </plist>

@ -4,14 +4,14 @@ const MAX_SMALL_SCREEN = 660;
const ONLY_NUMBERS = "[0-9]"; const ONLY_NUMBERS = "[0-9]";
const ONLY_LETTERS = "[a-zA-Z &'\"]"; const ONLY_LETTERS = "[a-zA-Z &'\"]";
const ONLY_DATE = "[0-9/]"; const ONLY_DATE = "[0-9/]";
// const BASE_URL_LIVE_CARE = 'https://livecare.hmg.com/'; const BASE_URL_LIVE_CARE = 'https://livecare.hmg.com/';
const BASE_URL_LIVE_CARE = 'https://uat.hmgwebservices.com/'; // const BASE_URL_LIVE_CARE = 'https://uat.hmgwebservices.com/';
const DOCTOR_ROTATION = 'https://doctorrota.hmg.com/'; const DOCTOR_ROTATION = 'https://doctorrota.hmg.com/';
// const BASE_URL = 'https://hmgwebservices.com/'; const BASE_URL = 'https://hmgwebservices.com/';
// const BASE_URL = 'http://10.20.200.111:1010/'; // const BASE_URL = 'http://10.20.200.111:1010/';
const BASE_URL = 'https://uat.hmgwebservices.com/'; // const BASE_URL = 'https://uat.hmgwebservices.com/';
// const BASE_URL = 'https://hmgwebservices.com/'; // const BASE_URL = 'https://hmgwebservices.com/';
@ -413,7 +413,7 @@ const TRANSACTION_NO = 0;
const LANGUAGE_ID = 2; const LANGUAGE_ID = 2;
const STAMP = '2020-04-27T12:17:17.721Z'; const STAMP = '2020-04-27T12:17:17.721Z';
const IP_ADDRESS = '9.9.9.9'; const IP_ADDRESS = '9.9.9.9';
const VERSION_ID = 9.8; const VERSION_ID = 9.9;
const CHANNEL = 9; const CHANNEL = 9;
const SESSION_ID = 'BlUSkYymTt'; const SESSION_ID = 'BlUSkYymTt';
const IS_LOGIN_FOR_DOCTOR_APP = true; const IS_LOGIN_FOR_DOCTOR_APP = true;

@ -115,7 +115,7 @@ class SickLeaveService extends BaseService {
Future getSickLeavePatient(patientMRN) async { Future getSickLeavePatient(patientMRN) async {
_sickLeavePatientRequestModel = SickLeavePatientRequestModel( _sickLeavePatientRequestModel = SickLeavePatientRequestModel(
patientID: patientMRN, patientTypeID: 2, patientType: 1); patientID: patientMRN, patientTypeID: 2, patientType: 1, patientMRN: patientMRN);
hasError = false; hasError = false;
getAllSickLeavePatient = []; getAllSickLeavePatient = [];
getAllSickLeavePatient.clear(); getAllSickLeavePatient.clear();

@ -35,7 +35,6 @@ Future<void> clearPrefsOnFirstLaunch() async {
await prefs.clear(); // Clear all prefs await prefs.clear(); // Clear all prefs
} }
class MyApp extends StatelessWidget { class MyApp extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
@ -60,7 +59,10 @@ class MyApp extends StatelessWidget {
) )
], ],
child: Consumer<ProjectViewModel>( child: Consumer<ProjectViewModel>(
builder: (context, projectProvider, child) => MaterialApp( builder: (context, projectProvider, child) => SafeArea(
top: false,
bottom: Platform.isAndroid ? true : false,
child: MaterialApp(
showSemanticsDebugger: false, showSemanticsDebugger: false,
title: 'Doctors App', title: 'Doctors App',
locale: projectProvider.appLocal, locale: projectProvider.appLocal,
@ -93,6 +95,7 @@ class MyApp extends StatelessWidget {
debugShowCheckedModeBanner: false, debugShowCheckedModeBanner: false,
), ),
), ),
),
); );
}); });
}, },

@ -11,11 +11,11 @@ description: A new Flutter project.
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at # Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version: 1.4.24+1 version: 1.4.26+1
environment: environment:
sdk: ">=3.5.0 <4.0.0" sdk: ">=3.6.0 <4.0.0"
#dependency_overrides: #dependency_overrides:
@ -41,8 +41,9 @@ dependencies:
# connectivity: ^3.0.6 # connectivity: ^3.0.6
connectivity_plus: ^6.1.4 connectivity_plus: ^6.1.4
maps_launcher: ^3.0.0+1 maps_launcher: ^3.0.0+1
url_launcher: ^6.3.1 url_launcher: ^6.3.2
url_launcher_ios: ^6.3.2 url_launcher_ios: ^6.3.2
url_launcher_android: ^6.3.17
charts_flutter: ^0.12.0 charts_flutter: ^0.12.0
#flutter_charts: ^0.5.2 #flutter_charts: ^0.5.2
#gelin: ^0.1.6 #gelin: ^0.1.6
@ -144,6 +145,7 @@ dependency_overrides:
intl: ^0.18.1 intl: ^0.18.1
flutter_plugin_android_lifecycle: 2.0.27 flutter_plugin_android_lifecycle: 2.0.27
#hijri_picker: ^3.0.0 #hijri_picker: ^3.0.0
path_provider: ^2.1.5
dev_dependencies: dev_dependencies:

Loading…
Cancel
Save