Commit Graph

123 Commits

Author SHA1 Message Date
6050fa745f Add ProfileTab and ProfileView widgets for user profile display
- Added ProfileTab widget for displaying user profile information in a tab.
- Added ProfileView widget for displaying user profile details in a separate view.
2024-04-23 16:38:26 +03:00
e47e428785 created Default Scaffold 2024-04-23 16:28:02 +03:00
6771785a4b removed old menu List and menu List Item models 2024-04-23 15:12:38 +03:00
1da61e7673 quick fixes 2024-04-23 15:11:10 +03:00
88588d9fa8 Refactor menu view to use sections and buttons
Extracted menu sections and buttons into separate data structures for better
organization and readability in the menu view. Updated MenuList widget to
dynamically render buttons based on the new data structure.
2024-04-23 15:11:01 +03:00
54982ba777 Configured ceiling presence sensor interface components
configured CPS UI to check for the state and the connectivity of the device.

reflected the data from the API to the UI
2024-04-22 11:49:21 +03:00
00e3c13d03 Add ParameterControlDialog for managing sensor parameters
This commit adds a new ParameterControlDialog widget to manage sensor
parameters in the presence sensors feature. The dialog allows users to
adjust sensitivity settings for ceiling sensors.
2024-04-22 10:14:11 +03:00
072a043aaa Moved wall sensor files 2024-04-22 10:13:40 +03:00
2eeee63e1d Update presence sensor interface and add parameter dialog
- Add parameter dialog for adjusting sensitivity in presence sensor interface.
- Implement toTitleCase helper method in StringHelpers class.
- Update UI elements in the presence sensor interface for better user interaction.
2024-04-22 09:14:02 +03:00
506068474b Add FunctionType enum and ValueModel class
- Added FunctionType enum with values Boolean, Enum, Integer, Raw, String.
- Introduced ValueModel class to handle unit, min, max, scale, and step values
  for functions in FunctionModel.
2024-04-21 16:13:51 +03:00
c3bc40e0d7 bugs fixed 2024-04-20 01:30:45 +03:00
e312d1fe4d Merge branch 'dev' into wall_mounted_sensor 2024-04-20 00:53:55 +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
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
09e0695bcc syncing to origin/dev 2024-04-17 16:29:27 +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
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
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
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
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
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
5dc4f96a71 Add functionality to fetch devices by room ID
Added a new method in DevicesCubit to fetch devices by room ID and updated
related classes and API calls to support this functionality.
2024-04-02 12:12:54 +03:00