Commit Graph

57 Commits

Author SHA1 Message Date
8594168548 hardcoded device location to dubai for demo purposes. 2025-06-30 14:22:54 +03:00
6ff9c602f1 SP-1723-FE-Integrate-Charts-with-API-s-for-AQI-sensor. 2025-06-16 10:59:51 +03:00
a0d9819532 Deleted FakeRangeOfAqiService. 2025-06-16 09:30:50 +03:00
5591c78d88 Refactor RemoteRangeOfAqiService to update API endpoint to match what the actual endpoint is. 2025-06-16 09:29:31 +03:00
c642ba2644 Revert "formatted all files."
This reverts commit 04250ebc98.
2025-06-12 16:04:49 +03:00
04250ebc98 formatted all files. 2025-06-12 15:33:32 +03:00
c6b55cb28b Sp 1594 device location api integration (#216)
<!--
  Thanks for contributing!

Provide a description of your changes below and a general summary in the
title

Please look at the following checklist to ensure that your PR can be
accepted quickly:
-->

## Jira Ticket
[SP-1594](https://syncrow.atlassian.net/browse/SP-1594)

## Description

1. Implemented `Bloc` and `Services` to integrate the device location
into the side panel of the AQI Analytics module.
2. Fixed bugs in side panel caused by `Expanded` widgets.

## Type of Change

<!--- Put an `x` in all the boxes that apply: -->

- [x]  New feature (non-breaking change which adds functionality)
- [x] 🛠️ Bug fix (non-breaking change which fixes an issue)
- [ ]  Breaking change (fix or feature that would cause existing
functionality to change)
- [ ] 🧹 Code refactor
- [ ]  Build configuration change
- [ ] 📝 Documentation
- [ ] 🗑️ Chore 


[SP-1594]:
https://syncrow.atlassian.net/browse/SP-1594?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
2025-06-04 16:41:08 +03:00
3a98f71ff3 SP-1665-FE-Return-a-readable-error-when-a-connection-error-Exception-occurs-on-the-charts. 2025-06-04 14:42:41 +03:00
24a7f3ac2a SP-1594-device-location-api-integration. 2025-06-04 13:06:27 +03:00
9fa59ce78b Merge branch 'dev' of https://github.com/SyncrowIOT/web into SP-1594-device-location-api-integration 2025-06-04 09:29:49 +03:00
8d999f118c Connected RemoteDeviceLocationService to the new BE API, instead of directly fetching the data from OpenWeather Api's. 2025-06-04 09:18:28 +03:00
bcb6e49a01 Deleted FakeDeviceLocationService class, since it is no longer needed. 2025-06-04 09:17:38 +03:00
8e11749ed7 Prepared for aqi distribution API Integration. 2025-06-02 16:13:58 +03:00
97801872e0 Implemented an initial remote implementation of RangeOfAqiService. 2025-06-02 14:29:04 +03:00
57b6f01177 SP-1593 Implemented the agreed upon api contract. 2025-06-02 14:26:47 +03:00
2e12d73151 randomize generated fake data in FakeAirQualityDistributionService. 2025-06-01 14:28:40 +03:00
4479ed04b7 Created a AirQualityDistributionService along with its fake implementation. 2025-06-01 14:22:25 +03:00
2c4da63266 Injected DeviceLocationBloc into AnalyticsPage. 2025-06-01 10:50:51 +03:00
5654d66b60 Created a remote implementation for DeviceLocationService. 2025-06-01 09:51:08 +03:00
b6879035f0 Implemented geocoding functionality to retrieve and manage device location data using the newly added geocoding package. 2025-05-29 15:47:34 +03:00
6ffb677c33 Created an interface and its fake implementation for loading device location data. 2025-05-29 15:40:15 +03:00
d90d3d4026 added loading state to range of aqi chart. 2025-05-27 12:29:06 +03:00
cb4956f915 made range of aqi fake data random and not linear. 2025-05-26 16:56:25 +03:00
296b03e1aa shows month data instead of index on bottom titles of RangeOfAqiChart. 2025-05-26 15:54:56 +03:00
d4dd7a19ba make the generated fake aqi range data, look better on the chart. 2025-05-26 11:21:42 +03:00
4a3085e1b4 Created RangeOfAqiService along with its fake implementation until the API is ready. 2025-05-26 11:00:57 +03:00
ecf588cfcb reverted to dynamic endpoint. 2025-05-21 10:58:21 +03:00
02b07cfdb6 Merge branch 'dev' of https://github.com/SyncrowIOT/web into SP-1510-occupancy_chart_api_integration 2025-05-21 10:23:56 +03:00
0a94557eee SP-1510-Occupancy Chart API Integration. 2025-05-21 10:23:31 +03:00
fd2a09cada Deleted unused FakeEnergyConsumptionPerDeviceService. 2025-05-20 14:22:23 +03:00
494ae1c941 SP-1495 reworks.
1. Overlapping line not removed.
2. The colors of the data on X axis and Y axis are not identical to design.
3. Day 1 and 2 are missing on the X axis.
4. When the chart loads, we see it coming from the top right corner (check the attached video).
5. Display all available devices even if they have no data and make the chart empty state.
2025-05-19 10:52:44 +03:00
7a073f10aa Merge pull request #189 from SyncrowIOT/1495-calendar-bugfixes
1495 calendar bugfixes
2025-05-15 14:31:11 +03:00
c07b53107e SP-1506-FE-chart per phase api integration. 2025-05-15 10:51:09 +03:00
8dfe8d10d4 removed requestType from query parameters of RemoteOccupancyAnalyticsDevicesService._makeRequest. 2025-05-15 10:01:43 +03:00
da481536c4 1495-energy-consumption-per-device-api-integration. 2025-05-14 16:55:28 +03:00
7515b347ce analytics devices integtation. 2025-05-14 15:03:30 +03:00
ac2b0d3fac Created an initial remote implementation of AnalyticsDevicesService. 2025-05-14 12:38:07 +03:00
3be7a377c0 Created AnalyticsDevicesService interface. 2025-05-14 12:37:52 +03:00
4d9e57c8b5 Created and connected a remote implementation that fetches the heat map occupancy per space from the API. 2025-05-14 10:51:37 +03:00
b7ef9da35d Sp 1513 fe implement device dropdown and live status card presence vacancy (#179)
* Called the widget of presence sensor status widgets.

* Enahnced `PowerClampEnergyDataDeviceDropdown` design and made it a dropdown.

* connected the realtime feature to the occupancy side bar, but with a mock id.

* revert default tab to energyManagement.
2025-05-11 16:59:15 +03:00
49e93329c8 Sp 1511 fe build occupancy heat map weekly monthly intensity view (#178)
* set the default tab to occupancy for ease of development.

* Implemented an initial design for the occupancy chart.

* Add Occupacy model and service for occupancy data handling.

* Created `OccupancyBloc`.

* Implemented the sidebar of Occupancy view.

* Moved `OccupancyEndSideBar` widget to its own file.

* Removed unnecessary widgets.

* Matched the `OccupancyChart` with the figma design.

* Added `AnalyticsDateFilterButton` to `OccupancyChartBox`.

* Hides `AnalyticsDateFilterButton` that is in the page header, when the selected tab isn't `AnalyticsPageTab.energyManagement`.

* Added animation to`AnalyticsDateFilterButton`.

* modified the implementation of `FakeOccupacyService` to clamp all the generated values to less than a 100.

* Injected `OccupancyBloc` into `AnalyticsPage`.

* Made `OccupancyChart` read its data from `OccupancyBloc`.

* Refactor AnalyticsCommunitiesSidebar to load data based on selected tab and implement loadEnergyManagementData method

* Refactor Analytics views to use StatefulWidget and load data in initState

* Created `OccupancyHeatMapModel`.

* Add FakeOccupancyHeatMapService implementation.

* Created `OccupancyHeatMapBloc`.

* Injected `OccupancyHeatMapBloc` into `AnalyticsPage`.

* Add OccupancyHeatMapBox widget and integrate into AnalyticsOccupancyView

* Matching the heat map with the design, and added week days.

* Made the HeatMap cells have a dashed border.

* shows months.

* responsiveness.

* Integrate OccupancyHeatMapBloc and update OccupancyHeatMapBox to display heat map data with error handling

* Integrate OccupancyHeatMapBloc and update OccupancyHeatMapBox to display heat map data with error handling

* made the heatmap loading fast af by using painters instead of individually creating a widget for every single event.

* Extracted `OccupancyHeatMapMonths` into its own widgte.

* Moved `OccupancyHeatMapMonths` to its own file.

* Adjusted design of `OccupancyHeatMapMonths`.

* Adjust layout flex properties for `OccupancyEndSideBar` and its parent column in `AnalyticsOccupancyView`.

* moved `OccupancyPaintItem` to `OccupancyPainter`s file.

* removed comments from `OccupancyPainter`.

* used color.withValues instead of .withOpacity.

* re-added `OccupancyHeatMapGradient`.

* Revert initial tab to `energyManagement`.

* Made datepicker dynamic for multiple states.

* Add year picker functionality to date filter button and implement dynamic date selection

* Align date filter button to the end in occupancy chart and heat map boxes for improved UI consistency.

* Enahnced color of border in `OccupancyPainter`.

* Add ClearOccupancyHeatMapEvent to reset heat map state and update occupancy data helper to trigger event on empty selections

* show percentage of value in tool tip of `OccupancyChart`.
2025-05-11 16:58:13 +03:00
d6f0b53b59 Sp 1494 api integration (#180)
* SP-1494-api-integration.

* fixed left stide titles intervals in total energy consumption chart.

* Adjusted tooltip and title intervals in energy management charts to improve accuracy by incrementing displayed values by one.

* Refactor AnalyticsCommunitiesSidebar to use AnalyticsSpaceTreeView and enhance community/space selection handling

* Gave every tab its own selection logic using the strategy design pattern, along with clearing the selection when changing tabes to avoid collision between features.
2025-05-11 16:46:00 +03:00
2e2bc99501 Merge pull request #176 from SyncrowIOT/SP-1510-FE-Build-Occupancy-Bar-Chart-Monthly-Consumption-View
Sp 1510 fe build occupancy bar chart monthly consumption view
2025-05-08 16:32:21 +03:00
bfb9158652 Replaced hardcoded device id from RemotePowerClampInfoService.getInfo, and instead used the one from the method parameter. 2025-05-07 15:47:41 +03:00
38ff20f86a Created initial remote implementation for all the services in the energy management module. 2025-05-07 11:28:31 +03:00
682e69e65f modify data to migrate to days instead of months. 2025-05-06 15:44:33 +03:00
d89e227599 removed unnecesary type annotations from FirebaseRealtimeDeviceService. 2025-05-06 09:06:33 +03:00
38184ca8b2 Integrated realtime data. 2025-05-05 16:58:48 +03:00
4d5de7bc05 making good progress on realtime data integration. 2025-05-05 16:34:56 +03:00
1a3006fa43 Power clamp info integration. 2025-05-05 12:57:27 +03:00