From 275fa5ca3a9219e3eae2dc65cbc384b72645c737 Mon Sep 17 00:00:00 2001 From: haroon amjad Date: Sun, 21 Jan 2024 13:04:02 +0300 Subject: [PATCH] Blood Pressure devices flow implemented --- .../lepu_device_types/bloodpressure_connect_screen.dart | 8 ++++---- .../my_trackers_view_model/my_trackers_view_model.dart | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/lib/pages/medical/my_trackers/ble_device_type_screens/lepu_device_types/bloodpressure_connect_screen.dart b/lib/pages/medical/my_trackers/ble_device_type_screens/lepu_device_types/bloodpressure_connect_screen.dart index 4a70468c..df56ba18 100644 --- a/lib/pages/medical/my_trackers/ble_device_type_screens/lepu_device_types/bloodpressure_connect_screen.dart +++ b/lib/pages/medical/my_trackers/ble_device_type_screens/lepu_device_types/bloodpressure_connect_screen.dart @@ -70,15 +70,15 @@ class _BloodPressureConnectScreenState extends State children: [ Column( children: [ - Text("Dia", style: TextStyle(fontSize: 20)), - Text(myTrackersViewModel.bpRtResultModel.dia.toString(), style: TextStyle(fontSize: 50, fontWeight: FontWeight.bold)), + Text("Sys", style: TextStyle(fontSize: 20)), + Text(myTrackersViewModel.bpRtResultModel.sys.toString(), style: TextStyle(fontSize: 50, fontWeight: FontWeight.bold)), Text("mmHg", style: TextStyle(fontSize: 10)), ], ), Column( children: [ - Text("Sys", style: TextStyle(fontSize: 20)), - Text(myTrackersViewModel.bpRtResultModel.sys.toString(), style: TextStyle(fontSize: 50, fontWeight: FontWeight.bold)), + Text("Dia", style: TextStyle(fontSize: 20)), + Text(myTrackersViewModel.bpRtResultModel.dia.toString(), style: TextStyle(fontSize: 50, fontWeight: FontWeight.bold)), Text("mmHg", style: TextStyle(fontSize: 10)), ], ), diff --git a/lib/pages/medical/my_trackers/my_trackers_view_model/my_trackers_view_model.dart b/lib/pages/medical/my_trackers/my_trackers_view_model/my_trackers_view_model.dart index f593dd34..80e5bd0a 100644 --- a/lib/pages/medical/my_trackers/my_trackers_view_model/my_trackers_view_model.dart +++ b/lib/pages/medical/my_trackers/my_trackers_view_model/my_trackers_view_model.dart @@ -166,11 +166,13 @@ class MyTrackersViewModel extends ChangeNotifier { clearEcgHistoryFiles() { ecgHistoryFiles.clear(); + ecgHistoryFiles = []; notifyListeners(); } parseEcgHistoryFiles(String mapData) { ecgHistoryFiles.clear(); + ecgHistoryFiles = []; json.decode(mapData).forEach((v) { ecgHistoryFiles.add(new ECGFileDetailModel.fromJson(v)); });