Merge branch 'master' into faiz_dev

# Conflicts:
#	lib/core/api/api_client.dart
faiz_dev
faizatflutter 3 days ago
commit 6bb04401cf

@ -263,7 +263,7 @@ class ApiClientImp implements ApiClient {
body: requestBody, body: requestBody,
headers: headers, headers: headers,
); );
log("response: ${response.body.toString()}"); // log("response: ${response.body.toString()}");
} on SocketException catch (e) { } on SocketException catch (e) {
final message = e.message.contains('Connection reset by peer') ? LocaleKeys.networkConnectionReset.tr() : LocaleKeys.networkErrorMessage.tr(); final message = e.message.contains('Connection reset by peer') ? LocaleKeys.networkConnectionReset.tr() : LocaleKeys.networkErrorMessage.tr();
onFailure(message, -1, failureType: ConnectivityFailure(message)); onFailure(message, -1, failureType: ConnectivityFailure(message));

@ -4,12 +4,14 @@ import 'dart:io';
import 'dart:math' as dartMath; import 'dart:math' as dartMath;
import 'dart:typed_data'; import 'dart:typed_data';
import 'package:clarity_flutter/clarity_flutter.dart';
import 'package:connectivity_plus/connectivity_plus.dart'; import 'package:connectivity_plus/connectivity_plus.dart';
import 'package:crypto/crypto.dart' as crypto; import 'package:crypto/crypto.dart' as crypto;
import 'package:easy_localization/easy_localization.dart'; import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart'; import 'package:flutter_svg/flutter_svg.dart';
import 'package:fluttertoast/fluttertoast.dart'; import 'package:fluttertoast/fluttertoast.dart';
import 'package:get_it/get_it.dart';
import 'package:google_api_availability/google_api_availability.dart'; import 'package:google_api_availability/google_api_availability.dart';
import 'package:hmg_patient_app_new/core/app_assets.dart'; import 'package:hmg_patient_app_new/core/app_assets.dart';
import 'package:hmg_patient_app_new/core/app_state.dart'; import 'package:hmg_patient_app_new/core/app_state.dart';

@ -94,7 +94,8 @@ class LoginScreenState extends State<LoginScreen> {
LocaleKeys.welcomeToDrSulaiman.tr(context: context).toText32(isBold: true, color: AppColors.textColor ), LocaleKeys.welcomeToDrSulaiman.tr(context: context).toText32(isBold: true, color: AppColors.textColor ),
SizedBox(height: 32.h), SizedBox(height: 32.h),
Localizations.override(context: context, locale: Locale('en', 'US'), child: Container()), // Force English locale for this widget Localizations.override(context: context, locale: Locale('en', 'US'), child: Container()), // Force English locale for this widget
TextInputWidget( ClarityUnmask(
child: TextInputWidget(
labelText: LocaleKeys.nationalIdFileNumber.tr(context: context), labelText: LocaleKeys.nationalIdFileNumber.tr(context: context),
hintText: "xxxxxxxxx", hintText: "xxxxxxxxx",
controller: authVm.nationalIdController, controller: authVm.nationalIdController,
@ -116,6 +117,7 @@ class LoginScreenState extends State<LoginScreen> {
authVm.clearNationalIdError(); authVm.clearNationalIdError();
}, },
), ),
),
SizedBox(height: 16.h), SizedBox(height: 16.h),
CustomButton( CustomButton(
height: 50.h, height: 50.h,
@ -205,7 +207,8 @@ class LoginScreenState extends State<LoginScreen> {
child: SingleChildScrollView( child: SingleChildScrollView(
child: Consumer<AuthenticationViewModel>( child: Consumer<AuthenticationViewModel>(
builder: (context, authVm, child) { builder: (context, authVm, child) {
return GenericBottomSheet( return ClarityUnmask(
child: GenericBottomSheet(
countryCode: authVm.selectedCountrySignup.countryCode, countryCode: authVm.selectedCountrySignup.countryCode,
initialPhoneNumber: "", initialPhoneNumber: "",
textController: phoneNumberController, textController: phoneNumberController,
@ -264,6 +267,7 @@ class LoginScreenState extends State<LoginScreen> {
), ),
), ),
], ],
),
); );
}, },
), ),

@ -63,12 +63,14 @@ class _ImmediateLiveCarePaymentPageState extends State<ImmediateLiveCarePaymentP
scheduleMicrotask(() { scheduleMicrotask(() {
payfortViewModel.initPayfortViewModel(); payfortViewModel.initPayfortViewModel();
myAppointmentsViewModel.getTamaraInstallmentsDetails().then((val) { myAppointmentsViewModel.getTamaraInstallmentsDetails().then((val) {
if (myAppointmentsViewModel.getTamaraInstallmentsDetailsResponseModel != null) {
if (num.parse(immediateLiveCareViewModel.liveCareImmediateAppointmentFeesList.total!) >= myAppointmentsViewModel.getTamaraInstallmentsDetailsResponseModel!.minLimit!.amount! && if (num.parse(immediateLiveCareViewModel.liveCareImmediateAppointmentFeesList.total!) >= myAppointmentsViewModel.getTamaraInstallmentsDetailsResponseModel!.minLimit!.amount! &&
num.parse(immediateLiveCareViewModel.liveCareImmediateAppointmentFeesList.total!) <= myAppointmentsViewModel.getTamaraInstallmentsDetailsResponseModel!.maxLimit!.amount!) { num.parse(immediateLiveCareViewModel.liveCareImmediateAppointmentFeesList.total!) <= myAppointmentsViewModel.getTamaraInstallmentsDetailsResponseModel!.maxLimit!.amount!) {
setState(() { setState(() {
isShowTamara = true; isShowTamara = true;
}); });
} }
}
}); });
}); });
super.initState(); super.initState();

@ -145,6 +145,8 @@ class _LandingPageState extends State<LandingPage> {
} }
if (appState.isAuthenticated) { if (appState.isAuthenticated) {
Clarity.setCustomUserId(appState.getAuthenticatedUser()!.patientId.toString());
habibWalletVM.initHabibWalletProvider(); habibWalletVM.initHabibWalletProvider();
habibWalletVM.getPatientBalanceAmount(); habibWalletVM.getPatientBalanceAmount();
habibWalletVM.getLakumAccountInformation(); habibWalletVM.getLakumAccountInformation();

@ -1,5 +1,6 @@
import 'dart:ui' as ui; import 'dart:ui' as ui;
import 'package:clarity_flutter/clarity_flutter.dart';
import 'package:easy_localization/easy_localization.dart'; import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
@ -405,6 +406,7 @@ class TextInputWidget extends StatelessWidget {
child: Localizations.override( child: Localizations.override(
context: context, context: context,
locale: const Locale('en', 'US'), // Force English locale for TextField locale: const Locale('en', 'US'), // Force English locale for TextField
child: ClarityUnmask(
child: TextField( child: TextField(
hintLocales: const [Locale('en', 'US')], hintLocales: const [Locale('en', 'US')],
enabled: isEnable, enabled: isEnable,
@ -466,6 +468,7 @@ class TextInputWidget extends StatelessWidget {
), ),
), ),
), ),
),
); );
}, },
); );

Loading…
Cancel
Save