Integration of Storage API to flutter - Users, Units 72/30172/8
authorLudwig Schwiedrzik <ludwig.schwiedrzik@d-fine.com>
Wed, 14 Aug 2024 09:50:33 +0000 (11:50 +0200)
committerScott Murray <scott.murray@konsulko.com>
Thu, 12 Sep 2024 16:58:42 +0000 (16:58 +0000)
commit7ea2d37528da61ff40a50da5843397d51fc0e789
treede3b9dcafda931aa3d0297c60bc2586c89e03782
parenta2dcd701777968a65d3176eaf28aa7023d97c16b
Integration of Storage API to flutter - Users, Units

Updated user and units notifiers to make use of persistent storage. New
users are stored with a name and id in the default namespace, and their
unit preferences (distance, temperature, tire pressure) are stored in
namespaces corresponding to each user's id.

Added new initialize_settings to load user and unit settings from
storage on startup. For first-time startup, default users with ids have
been added to storage as well.

Added unit tests for new user and unit handling.

Bug-AGL: [SPEC-5228]
Change-Id: I9cbcfc3ea5045dcb27db1b05e332f89abfc284a1
Signed-off-by: Tom Kronsbein <tom.kronsbein@d-fine.com>
Signed-off-by: Ludwig Schwiedrzik <ludwig.schwiedrzik@d-fine.com>
lib/core/constants/users_path.dart [new file with mode: 0644]
lib/data/data_providers/app.dart
lib/data/data_providers/initialize_settings.dart [new file with mode: 0644]
lib/data/data_providers/units_notifier.dart
lib/data/data_providers/users_notifier.dart
lib/data/models/users.dart
lib/export.dart
lib/main.dart
test/storageAPI_UnitsForUsers_test.dart [new file with mode: 0644]