Commit Graph

490 Commits

Author SHA1 Message Date
e312d1fe4d Merge branch 'dev' into wall_mounted_sensor 2024-04-20 00:53:55 +03:00
5a07f6a86c Merge pull request #15 from SyncrowIOT/ceiling_mounted_page
Ceiling_mounted_page
2024-04-19 17:58:58 +03:00
bb56ea42c5 Remove unused imports
Remove unused imports from multiple files in the project.
2024-04-19 17:48:18 +03:00
d78394d259 Add presence indicator and wall sensor interface 2024-04-19 17:47:49 +03:00
822de1d9b5 Add presence sensor assets to pubspec.yaml 2024-04-19 17:46:30 +03:00
f095d29022 Added wall mounted presence sensor assets 2024-04-18 10:01:55 +03:00
b433cd07e6 Added ceiling sensor interface
Add a new widget for displaying the interface of a ceiling sensor device.
This widget includes UI elements to show sensor data and control options.
2024-04-18 09:51:23 +03:00
1ec1ae76b0 Added ceiling presence sensor assets 2024-04-18 09:50:32 +03:00
09e0695bcc syncing to origin/dev 2024-04-17 16:29:27 +03:00
ff71002ee0 Merge pull request #14 from SyncrowIOT/doorlock_interface
Doorlock_interface
2024-04-17 15:58:47 +03:00
98f14a56f5 Merge branch 'dev' into doorlock_interface 2024-04-17 14:01:54 +03:00
97f3ebc583 Changed Size and Shadows in the door lock button containers 2024-04-17 13:59:55 +03:00
136d681182 Merge pull request #13 from SyncrowIOT/token_validation
Refactor HTTPInterceptor and add CustomSnackBar helper
2024-04-17 12:06:00 +03:00
f4304f1296 Added onTap to DefaultContainer 2024-04-17 12:04:59 +03:00
086476810c Improved The layout of Door Lock Page 2024-04-17 11:31:09 +03:00
6266780258 Update form key to be a final field and add validators for email and password
- Make the form key a final field in the AuthCubit class
- Add validators for email and password fields in the AuthCubit class
- Update the LoginForm widget to use the form key from AuthCubit class
- Add validators for email and password fields in the LoginForm widget
2024-04-16 16:44:17 +03:00
fd03d29e93 Avoided null value in network_exception.dart when calling fromResponse 2024-04-16 15:47:03 +03:00
214c4bb749 Remove unnecessary developer log statements 2024-04-16 15:45:32 +03:00
95f7ade9e6 removed try-catch blocks from auth_api.dart, devices_api.dart and spaces_api.dart files 2024-04-16 15:45:04 +03:00
cc6b68e338 Update device interfaces and add new doors list view widget
- Add a new widget 'DoorsListView' for displaying a list of smart doors
- Update the navigation method to devices interfaces in 'RoomPageSwitch' widget
- Add battery and doorlock icons to auto generated assets
2024-04-16 14:53:43 +03:00
cbe4fb285b Add smart door widgets
Added new widgets for a smart door feature including a door button, grid, status bar, and interface. Also included assets and functionality for door lock buttons.
2024-04-16 14:51:18 +03:00
9904a8cc0b Added door lock assets 2024-04-16 14:49:17 +03:00
df13c66b1a Refactor API error handling and add try-catch blocks
Added try-catch blocks for error handling in API's files to rethrow the errors to the cubit so cubits can update the UI based on them.

Refactored error handling in HTTPInterceptor and HTTPService classes.
2024-04-15 15:47:13 +03:00
dd90a2133f removed snackbar calling in any place in the app except in the intercepter to improve
readability and reduce duplication of error message display logic.
2024-04-15 15:44:32 +03:00
80d424f114 Refactor code for consistency and readability
- Removed unused imports and commented-out code
- Updated class inheritance for AuthState subclasses
- Reorganized code structure for better readability
- Cleaned up debug print statements and replaced with dart:developer logs
2024-04-15 12:03:25 +03:00
cfc395e210 Refactor HTTPInterceptor and add CustomSnackBar helper
Refactor HTTPInterceptor to handle error responses and add a CustomSnackBar
helper to display snack bars. This will improve error handling and user
feedback in the application.
2024-04-15 12:02:34 +03:00
590c70a7d8 Merge pull request #12 from SyncrowIOT/Configure_devices_statuses
Configure devices statuses
2024-04-14 12:01:57 +03:00
2ae0c07830 Update import statements from relative tok apsulote paths. 2024-04-13 18:05:19 +03:00
696ff25b6a Update import paths from relative to abslute path accross the entire application. 2024-04-07 12:57:26 +03:00
6dfce18703 Refactor UI structure in curtain and light widgets
Simplify UI structure in curtain_view.dart and light_interface.dart by
rearranging the widget tree for better readability and maintainability.
2024-04-07 12:50:12 +03:00
af7b497cdb apend 2024-04-04 15:51:58 +03:00
8c80283f9c Update DefaultNavBar widget and ServerFailure class
Refactor DefaultNavBar widget to update page index on item tap.
Update ServerFailure class to handle 400 status code with list of errors.
2024-04-04 15:51:41 +03:00
a0c553f9ae Refactor ServerFailure class to use 'message' field from response
Update ServerFailure class to extract error message from 'message' field in
response data instead of converting the entire data to a string.
2024-04-04 14:53:58 +03:00
81242c69cb Update CustomSwitch widget to handle device status and control
Refactored CustomSwitch widget to properly handle device status and control
based on the device's status values. Added necessary checks and updated UI
accordingly.
2024-04-04 01:35:30 +03:00
65112976b2 Update device control logic for three gang interface
Refactor onTap functions in ThreeGangInterfaceBody to control all three switches
simultaneously based on the user interaction. Split the logic for turning on and
off the switches into separate functions for better readability and maintenance.
2024-04-04 01:18:02 +03:00
245ab82208 Refactor GangSwitch widget and ThreeGangInterfaceBody
Refactor GangSwitch widget and ThreeGangInterfaceBody for better readability
and maintainability. Update widget structure and logic for improved
functionality and code organization.
2024-04-04 01:14:55 +03:00
1f4fb940bc apend 2024-04-04 00:50:27 +03:00
20ded336d3 Refactor AC interface temp unit control logic
Refactor the control logic in the AC interface temp unit widget to handle
device control actions more efficiently and improve code readability.
2024-04-04 00:45:54 +03:00
13bfcdfb4d Update device icons and refactor AC interface widget
- Update device icons to match new design requirements
- Refactor AC interface widget to use a more descriptive variable name
- Implement temperature control functionality in AC interface widget
2024-04-04 00:38:27 +03:00
37d2c1b53f apend 2024-04-04 00:01:02 +03:00
8d02eb2f40 Refactor DefaultNavBar widget build method
Remove unnecessary BlocProvider and DevicesCubit logic from DefaultNavBar widget
build method, simplify code structure.
2024-04-04 00:00:48 +03:00
bff4b9493c Refactor device control logic and add temperature and fan speed enums
- Refactor device control logic in the app to improve readability and maintainability.
- Add temperature modes (hot, cold, wind) and fan speeds (auto, low, middle, high) enums.
- Update icon mappings and utility functions for temperature modes and fan speeds.
2024-04-03 18:54:21 +03:00
6577652702 Refactor AC mode control unit widget
Move fan speed and temperature mode logic to the DevicesCubit for better
separation of concerns and improved code readability. Update widget to use
BlocBuilder for state management and simplify control logic.
2024-04-03 18:53:54 +03:00
e49627d3e1 Add status model and fetch device statuses
Added a new StatusModel class to represent device statuses and implemented
functionality to fetch and update device statuses in the DevicesCubit and
DeviceModel classes. Also updated UI components to display device status
information.
2024-04-03 11:07:55 +03:00
5ff5f65549 Refactor emit calls to use emitSafe method
Replace direct calls to emit with emitSafe method to ensure emitting
states only when the cubit is not closed. This helps prevent errors
when emitting states after the cubit is closed.
2024-04-03 02:12:35 +03:00
313912a941 Fixed conditional rendering logic for app bar in AppLayout widget
Update the condition to check for the presence of spaces in HomeCubit
instance before displaying the DefaultAppBar component. This improves
readability and maintainability of the code.
2024-04-03 02:00:46 +03:00
127d3a0295 Refactor code structure and update dependencies
Clean up code structure, remove unused imports, and update dependencies.
No functional changes made, only code organization improvements.
2024-04-03 01:55:50 +03:00
9cc479ba17 Refactor email and password validation logic in LoginForm widget
Update email and password validation logic in the LoginForm widget to only
perform validation when the state is not AuthTokenError. This ensures that
validation is skipped when there is an authentication token error.
2024-04-02 18:09:23 +03:00
ef41940333 Add support for different device types in RoomPageSwitch
-Update the navigation approch to be device type orianted to the corresponding interface when tapped.
-Add three gang switch interface and related components
2024-04-02 15:45:21 +03:00
81625cd50e Add device icons based on device type and update network exception handling
- Add logic to set device icons based on device type in DeviceModel.fromJson method
- Update network exception handling to parse HTML response in ServerFailure class
- Add html package as a dependency for parsing HTML responses
-Added Devices Icons by updateing device types mapping
2024-04-02 15:11:20 +03:00