diff --git a/lib/pages/landing/landing_page.dart b/lib/pages/landing/landing_page.dart index 4bf1e44f..44285892 100644 --- a/lib/pages/landing/landing_page.dart +++ b/lib/pages/landing/landing_page.dart @@ -654,10 +654,11 @@ class _LandingPageState extends State with WidgetsBindingObserver { authService.getDashboard().then((value) async { setState(() { if (value != null) { + notificationCount = value['List_PatientDashboard'][0]['UnreadPatientNotificationCount'] > 99 ? '99+' : value['List_PatientDashboard'][0]['UnreadPatientNotificationCount'].toString(); model.setState(model.count, model.ancillaryCount, true, notificationCount); sharedPref.setString(NOTIFICATION_COUNT, notificationCount); - // FlutterAppIconBadge.updateBadge(int.parse(notificationCount)); + checkLastLoginStatus(); } }); // if (await AppSharedPreferences().getBool(IS_LAST_APPOINTMENT_RATE_SHOWN) == null || !await AppSharedPreferences().getBool(IS_LAST_APPOINTMENT_RATE_SHOWN)) { @@ -703,4 +704,13 @@ class _LandingPageState extends State with WidgetsBindingObserver { void showUserConsent() { sharedPref.setString(IS_COVID_CONSENT_SHOWN, "true"); } + + checkLastLoginStatus() async{ + int lastLoginStatus = await sharedPref.getInt(LAST_LOGIN) != null ? await sharedPref.getInt(LAST_LOGIN) : 1; + + if(lastLoginStatus == 1 || lastLoginStatus == 2){ + print("SMS or Whatsapp Consent"); + } + + } }