Commit graph

10 commits

Author SHA1 Message Date
Justin Bassett 195bc9601c Reload UI url more proactively (#275)
* Reload UI if the base url has changed.
AKA changed from remote/local.

* Linting.

* Now we don't rebuild dagger every time we change urls.
Need to fix tests.

* Test and comment.
2020-01-19 13:51:10 -08:00
Justin Bassett cf283cf662 Fix migration to pull from the correct preference. (#246) 2020-01-10 19:52:02 +01:00
Justin Bassett 5f54896057 Support Migrations (#224)
* Add instanceId to data layer.

* Support migrations.

* Formatting

* Make sure version is set.

* Validate migrations working.
2020-01-08 22:51:57 +01:00
Justin Bassett 5d02ec9bc6
Send device_id for HA versions above 0.104.0 (#234) 2020-01-08 15:49:38 -05:00
Justin Bassett ffdc3c3750 Home Network Settings (#209)
* Url management now abstracted to new separate use case.

* Add preferences for URLS.

* Add wifi ssid check.

* Tests now passing!

* Now show error and bring to settings when can't connect.

* Fix PR comments.

* Home SSID tracking now working.
Also go to settings if refresh token fails.

* Fix test.

* isInternal is now optional, we can determine in the repository if needed.

* Rework preferences ordering and disable when not used.

* Extract strings.

* Add validation of URLs.

* Formatting.

* Fix tests.
2020-01-03 11:43:25 +01:00
Justin Bassett 715ca9e362 Allow editing of Device Name (#158)
* Migrate preference categories to string resource.
Disable lint for missing translations.

* We now can change the device name.

* Linting Fixes.

* Tests a functional, now to add new tests.

* Fix all the tests for real this time.
Fix clean task being in wrong group.

* Add tests for persisting device registration.

* Extract string, remove summary, use androidx preferences.

* Migrate to injection and constants for registration data that is build time.

* Use SimpleSummaryProvider.

* Revert global missing translation lint error.

* Disable MissingTranslation lint globally.
2019-12-19 16:40:26 +01:00
Justin Bassett 594936c088 Feature/location settings (#129)
* Initial work on zone based location tracking.

* Tests and enhancements.

* Fix unit tests.

* Fix test cases.

* Initial location preferences work.

* Location settings now function will requests for permissions when needed.

* ktlink formatting.

* Domain tests.

* Data tests

* Extract strings into resources.

* Remove translations until Lokalise SDK is added back.
Failing lint

* Update wording.

* Add icons and toolbar.

* Coloring the settings.
2019-12-11 14:02:31 -06:00
Marcio Granzotto Rodrigues 7d7fc0bd6e Code formatting and linter (#73)
* add ktlint to the project

* Auto format and fix linter issues

* Add Quality section to README
2019-12-01 09:05:37 +01:00
Justin Bassett ea56328a52 Initial work on integrating the mobile_app component. (#25)
* Initial work on integrating the mobile_app component.

* Tests because even if I don't like to write them, I probably should.

* Remove unused dependency for now.

* Fix view related PR comments, migrate to view flipper to make more
consistent with other UI.

* Migrate from error handling at Repository to Presenter for Integration.

* Extract register device data class.

* Extract the mapping of DeviceRegistration to RegisterDeviceRequest.

* Extract ensuring we have a valid, refreshed session.

* Unique localStorage per usage to avoid name collision.
2019-11-15 07:59:41 +01:00
Cedrick Flocon 3219504a12 [ARCHITECTURE] Let's do some quality (#15)
* extract dependencies

* Update test command and add lint

* Move Retrofit into data module and test authentication service

* Implement authorization repository

* Implementation authentication usecase

* Implementation presenter layer

* Remove old session stuff

* Java time backport

* Dependency with dagger
2019-11-10 13:07:38 -08:00