diff --git a/android/build.gradle.kts b/android/build.gradle.kts index b703166b..29a4e9da 100644 --- a/android/build.gradle.kts +++ b/android/build.gradle.kts @@ -63,6 +63,15 @@ allprojects { } subprojects { + project.buildscript.repositories { + google() + mavenCentral() + } + + project.repositories { + google() + mavenCentral() + } afterEvaluate { if (project.hasProperty("android")) { project.extensions.findByName("android")?.let { androidExt -> diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties index fe111165..4ee62d8f 100644 --- a/android/gradle/wrapper/gradle-wrapper.properties +++ b/android/gradle/wrapper/gradle-wrapper.properties @@ -3,4 +3,4 @@ distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists #distributionUrl=https\://services.gradle.org/distributions/gradle-8.12-all.zip -distributionUrl=https\://services.gradle.org/distributions/gradle-8.14-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-all.zip diff --git a/android/settings.gradle.kts b/android/settings.gradle.kts index c6e1e3b1..434a4219 100644 --- a/android/settings.gradle.kts +++ b/android/settings.gradle.kts @@ -16,6 +16,26 @@ pluginManagement { } } +dependencyResolutionManagement { +// repositoriesMode.set(RepositoriesMode.PREFER_SETTINGS) + repositoriesMode.set(RepositoriesMode.PREFER_PROJECT) + repositories { + google() + mavenCentral() + maven { + url = uri("https://storage.googleapis.com/download.flutter.io") + } + // Huawei HMS repo + maven { + url = uri("https://developer.huawei.com/repo/") + } + // Mapbox repo + maven { + url = uri("https://api.mapbox.com/downloads/v2/releases/maven") + } + } +} + plugins { id("dev.flutter.flutter-plugin-loader") version "1.0.0" // id("com.android.application") version "8.9.3" apply false diff --git a/lib/core/api/api_client.dart b/lib/core/api/api_client.dart index 7a72e251..07198caa 100644 --- a/lib/core/api/api_client.dart +++ b/lib/core/api/api_client.dart @@ -209,7 +209,7 @@ class ApiClientImp implements ApiClient { body['TokenID'] = "@dm!n"; } - body['TokenID'] = "@dm!n"; + // body['TokenID'] = "@dm!n"; // body['PatientID'] = 7000792; // body['PatientID'] = 53320; // body['PatientTypeID'] = 1; diff --git a/lib/core/api_consts.dart b/lib/core/api_consts.dart index c7621289..6a65e92f 100644 --- a/lib/core/api_consts.dart +++ b/lib/core/api_consts.dart @@ -317,7 +317,7 @@ class ApiConsts { // ************ static values for Api **************** // static final double appVersionID = 21.9; - static final double appVersionID = 21.3; + static final double appVersionID = 21.4; // static final double appVersionID = 50.7; static final int appChannelId = 3; diff --git a/lib/presentation/habib_wallet/wallet_payment_confirm_page.dart b/lib/presentation/habib_wallet/wallet_payment_confirm_page.dart index 52cea368..101e2359 100644 --- a/lib/presentation/habib_wallet/wallet_payment_confirm_page.dart +++ b/lib/presentation/habib_wallet/wallet_payment_confirm_page.dart @@ -7,7 +7,6 @@ import 'package:clarity_flutter/clarity_flutter.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; -import 'package:flutter_amazonpaymentservices/flutter_amazonpaymentservices.dart'; import 'package:hmg_patient_app_new/core/api_consts.dart'; import 'package:hmg_patient_app_new/core/app_assets.dart'; import 'package:hmg_patient_app_new/core/app_state.dart'; @@ -830,28 +829,4 @@ class _WalletPaymentConfirmPageState extends State { "", "3"); } - - Future runSafePayment(Map requestParam, {String sdkToken = ""}) async { - dynamic result; - - try { - // Force a 100ms microtask buffer to isolate the UI rendering channel - await Future.delayed(const Duration(milliseconds: 350)); - - result = await FlutterAmazonpaymentservices.normalPay(requestParam, ApiConsts.payFortEnvironmentType, isShowResponsePage: true); - - print("Payment Success Data: ${result.toString()}"); - } on PlatformException catch (e) { - // If the error is the MethodChannel duplicate reply bug, handle it safely - if (e.message != null && e.message!.contains("Reply already submitted")) { - print("Swallowed native channel race-condition crash safely."); - return; - } - - // Process real payment rejection errors here - print("Actual Payment Failure: ${e.details.toString()}"); - } catch (error) { - print("Generic Error: $error"); - } - } } diff --git a/lib/services/localauth_service.dart b/lib/services/localauth_service.dart index 2875a7fe..cdce9005 100644 --- a/lib/services/localauth_service.dart +++ b/lib/services/localauth_service.dart @@ -17,10 +17,12 @@ class LocalAuthService { final isAuthenticated = await localAuth.authenticate( localizedReason: 'Please authenticate to proceed', - options: const AuthenticationOptions( - biometricOnly: true, - stickyAuth: true, - ), + persistAcrossBackgrounding: false, // Replaces stickyAuth + biometricOnly: true, + // options: const AuthenticationOptions( + // biometricOnly: true, + // stickyAuth: true, + // ), ); return isAuthenticated; diff --git a/lib/services/security_service.dart b/lib/services/security_service.dart index b72dffeb..2af9c45a 100644 --- a/lib/services/security_service.dart +++ b/lib/services/security_service.dart @@ -82,7 +82,7 @@ class SecurityServiceImpl implements SecurityService { onObfuscationIssues: () => _handleThreat('Obfuscation Issues', ThreatSeverity.warning), onDebug: () => _handleThreat('Debug Mode', ThreatSeverity.critical), onDeviceBinding: () => _handleThreat('Device Binding', ThreatSeverity.critical), - onDeviceID: () => _handleThreat('Device ID Mismatch', ThreatSeverity.critical), + onDeviceID: () => _handleThreat('Device ID Mismatch', ThreatSeverity.warning), onHooks: () => _handleThreat('Hooks Detected', ThreatSeverity.critical), onPasscode: () => _handleThreat('Passcode Not Set', ThreatSeverity.warning), onPrivilegedAccess: () => _handleThreat('Privileged Access (Root/Jailbreak)', ThreatSeverity.critical), diff --git a/lib/splashPage.dart b/lib/splashPage.dart index 0b43ae63..b1d03c80 100644 --- a/lib/splashPage.dart +++ b/lib/splashPage.dart @@ -93,9 +93,6 @@ class _SplashScreenState extends State { if (isAppOpenedFromCall) { navigateToTeleConsult(); } else { - // if (Utils.havePrivilege(124)) { - // Navigator.of(getIt.get().navigatorKey.currentContext!).pushAndRemoveUntil(CustomPageRoute(page: AppClosedPage()), (r) => false); - // } else { if (await Utils.getBoolFromPrefs(CacheConst.firstLaunch)) { // Navigator.of(context).pushReplacement(FadePage(page: SplashAnimationScreen(routeWidget: OnboardingScreen()))); Navigator.of(getIt.get().navigatorKey.currentContext!).pushReplacement(FadePage(page: OnboardingScreen())); @@ -105,7 +102,6 @@ class _SplashScreenState extends State { } } } - // } }); // var zoom = ZoomVideoSdk(); diff --git a/pubspec.yaml b/pubspec.yaml index e18f2205..c6bc2c93 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -2,8 +2,8 @@ name: hmg_patient_app_new description: "New HMG Patient App" publish_to: 'none' # Remove this line if you wish to publish to pub.dev -#version: 4.6.044+1 -version: 4.6.1002+40501002 +#version: 4.6.046+1 +version: 4.6.1004+40501004 environment: sdk: ">=3.6.0 <4.0.0" @@ -17,8 +17,8 @@ dependencies: cached_network_image: ^3.4.1 http: ^1.5.0 flutter_svg: ^2.2.0 - shared_preferences: ^2.5.3 - connectivity_plus: ^6.1.5 + shared_preferences: ^2.5.5 + connectivity_plus: ^7.3.1 auto_size_text: ^3.0.0 shimmer: ^3.0.0 sizer: ^3.1.3 @@ -45,7 +45,7 @@ dependencies: flutter_ios_voip_kit_karmm: ^0.8.0 image_picker: ^1.2.0 file_picker: 10.3.8 - local_auth: ^2.3.0 + local_auth: ^3.0.2 share_plus: ^11.1.0 device_calendar_plus: path: ./package/device_calendar_plus @@ -107,8 +107,10 @@ dependencies: in_app_review: ^2.0.11 flutter_paytabs_bridge: ^2.7.14 - clarity_flutter: 1.9.0 - flutter_amazonpaymentservices: ^0.0.13 + clarity_flutter: ^1.10.0 +# flutter_amazonpaymentservices: ^0.0.13 + flutter_amazonpaymentservices: + path: ./package/flutter_amazonpaymentservices screen_brightness: ^1.0.1 flutter_screenshot_blocker: ^1.0.4 cloudflare_turnstile: ^3.7.2