Skip to content

WIP: Default weight using profile#1207

Open
jmccaull wants to merge 2 commits into
wger-project:masterfrom
jmccaull:default-weight-profile
Open

WIP: Default weight using profile#1207
jmccaull wants to merge 2 commits into
wger-project:masterfrom
jmccaull:default-weight-profile

Conversation

@jmccaull
Copy link
Copy Markdown

Alternative to #1181. If this change set is preferred I will update the tests.

Proposed Changes

  • refactor main app to provide UserProvider as a dependency for RoutineProvider
  • remove default weight unit from set config data
  • adjust RoutineProvider.defaultWeightUnit to use UserProvider''s metric setting
  • adjust RoutineProvider logic to utilize defaultWeightUnit when none provided

Related Issue(s)

Closes #1180

Please check that the PR fulfills these requirements

  • Tests for the changes have been added (for bug fixes / features)
  • Set a 100-character limit to avoid white space diffs (run dart format .)

@jmccaull
Copy link
Copy Markdown
Author

The plate provider probably also needs to be refactored, but for that UserProvider would also need to first be converted to riverpod, correct? Do you want that addressed here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use plate selection to imply default weight unit

1 participant