Commit Graph

408 Commits

Author SHA1 Message Date
Roland Geider
ea41b49051 If there is no session known locally, just re-fetch the whole routine 2025-03-19 10:15:43 +01:00
Roland Geider
f987de1b4d Handle case where an exercise has no variations 2025-03-18 14:59:33 +01:00
Roland Geider
5fdcb63207 Remove the optional refresh parameter
We always want to refresh the data since we don't update manually the
dayData lists
2025-03-17 19:27:43 +01:00
Roland Geider
2a422958f6 Remove commented code 2025-03-17 09:57:44 +01:00
Roland Geider
4e959d777a The repetition and weight units can be null
and don't need to be loaded in this case
2025-03-16 19:59:00 +01:00
Roland Geider
753a126625 Don't load templates
At the moment templates are not supported in the mobile app.
2025-03-15 14:55:14 +01:00
Roland Geider
325cc93865 Refresh the whole routine after modifying further objects.
This makes sure that all the structures are present and have the correct
content (dayData, etc.). Also, add more feedback to the user for some operations
that take a bit longer due to loading the whole routine.
2025-03-11 20:36:38 +01:00
Roland Geider
929acc7938 Refresh the whole routine after modifying a day
This makes sure that all the structures are present and have the correct
content (dayData, etc.)
2025-03-11 14:06:09 +01:00
Roland Geider
2f975b1fd3 Correctly handle the state
The problem was that some of the previous changes were asynchronous and would
not always represent the actual current state. This solution works, but is
a bit verbose and perhaps overly complicated?
2025-02-22 23:09:59 +01:00
Roland Geider
eecaa6fcf0 Merge branch 'feature/flexible-routines' into Jackpkn-fix/gym-provider-navigation 2025-02-21 22:16:25 +01:00
Roland Geider
f25e9867a2 Cleanup 2025-02-21 22:05:29 +01:00
Roland Geider
14a5d7285b Extract the day data for the current routine
instead of loading the same data from the server
2025-02-16 21:19:17 +01:00
Roland Geider
460b6e7125 Add smoke test for fetchAndSetRoutineFull 2025-02-02 22:38:05 +01:00
Roland Geider
2498183094 Rename further instances of "reps" to "repetitions" 2025-02-01 19:24:15 +01:00
Roland Geider
3ef8b62d53 Update exercise info API paths 2025-02-01 15:29:14 +01:00
Roland Geider
110c98ffbd Merge branch 'feature/flexible-routines' into Jackpkn-fix/gym-provider-navigation 2025-01-31 21:33:57 +01:00
Roland Geider
8256c46d4f Initialize the units for the log entries in the session 2025-01-31 17:52:47 +01:00
Roland Geider
3e6ee0b082 Update models due to changes in exercise api response changes 2025-01-30 21:48:44 +01:00
Roland Geider
4bd16f5c0d Remove logs from the routine
The logs are now in the session list and can be easily extracted if needed
2025-01-30 18:21:09 +01:00
Roland Geider
7c6fbebdf5 Show workout session information 2025-01-26 20:11:21 +01:00
Roland Geider
6869dc9789 Use logging package for debug messages in routines provider 2025-01-26 15:12:01 +01:00
Roland Geider
b4f8a59a70 Add the newly created session to the routine 2025-01-26 15:07:37 +01:00
Roland Geider
c0935506ed Load the session data from the new API as well
Also, edit or add a session in the gym mode
2025-01-25 21:50:30 +01:00
Roland Geider
202349c5bc Make workout log charts work again 2025-01-25 15:39:51 +01:00
Roland Geider
58d60310e7 Merge branch 'master' into feature/flexible-routines
# Conflicts:
#	lib/main.dart
#	lib/providers/exercises.dart
#	lib/providers/workout_plans.dart
#	lib/screens/home_tabs_screen.dart
#	pubspec.yaml
2025-01-25 12:50:37 +01:00
Roland Geider
58e7a52e3d Use log levels when logging to console 2025-01-25 12:45:33 +01:00
Roland Geider
4d55f8c901 Add some more tests 2025-01-24 20:22:22 +01:00
Roland Geider
ce9c225358 Don't break from the loop immediately 2025-01-24 16:59:41 +01:00
Roland Geider
1e94395599 Replace day list 2025-01-24 15:13:29 +01:00
Roland Geider
eff176f035 Merge branch 'master' into feature/flexible-routines
# Conflicts:
#	lib/main.dart
#	lib/models/exercises/exercise.dart
#	lib/models/exercises/exercise_api.freezed.dart
#	lib/models/workouts/day.g.dart
#	lib/models/workouts/session.g.dart
#	lib/models/workouts/workout_plan.g.dart
#	lib/providers/exercises.dart
#	lib/widgets/core/settings.dart
#	pubspec.lock
#	test/auth/auth_screen_test.mocks.dart
#	test/core/settings_test.mocks.dart
#	test/exercises/contribute_exercise_test.mocks.dart
#	test/gallery/gallery_form_test.mocks.dart
#	test/gallery/gallery_screen_test.mocks.dart
#	test/measurements/measurement_categories_screen_test.mocks.dart
#	test/measurements/measurement_provider_test.mocks.dart
#	test/nutrition/nutritional_meal_form_test.mocks.dart
#	test/nutrition/nutritional_plan_form_test.mocks.dart
#	test/nutrition/nutritional_plan_screen_test.mocks.dart
#	test/nutrition/nutritional_plans_screen_test.mocks.dart
#	test/other/base_provider_test.mocks.dart
#	test/user/provider_test.mocks.dart
#	test/weight/weight_provider_test.mocks.dart
#	test/weight/weight_screen_test.mocks.dart
#	test/workout/gym_mode_screen_test.mocks.dart
#	test/workout/repetition_unit_form_widget_test.mocks.dart
#	test/workout/routine_screen_test.mocks.dart
#	test/workout/routines_provider_test.mocks.dart
#	test/workout/routines_screen_test.mocks.dart
#	test/workout/weight_unit_form_widget_test.mocks.dart
#	test/workout/workout_day_form_test.mocks.dart
#	test/workout/workout_form_test.mocks.dart
#	test/workout/workout_set_form_test.mocks.dart
2025-01-24 15:05:28 +01:00
Roland Geider
dad109d5bd Inject the shared preferences class for easier testing 2025-01-24 13:59:08 +01:00
Roland Geider
9d9f276476 Merge branch 'fork/Sangharshdeveloper/feature-theme_customization#687'
# Conflicts:
#	pubspec.lock
2025-01-23 23:23:12 +01:00
Roland Geider
86f8b7ae35 Add a third option to the theme mode
This allows the user to use the system settings as well, and not always force
light or dark mode in the app. Also move the logic to the UserProvider and
do some light refactoring.
2025-01-23 23:22:50 +01:00
Roland Geider
eac2397396 Add workaround for #722 2025-01-22 19:29:17 +01:00
Jackpkn
167b246f60 added setDayId function in gym_state 2025-01-19 23:40:33 +05:30
Roland Geider
9ab55a6c83 Save iteration and slot entry id to the logs 2025-01-18 16:46:08 +01:00
Roland Geider
9bb3567835 Add day id to the gym state provider 2025-01-18 15:15:42 +01:00
Roland Geider
f5ab51fd5b Repetitions are not integers anymore 2025-01-18 13:55:42 +01:00
Roland Geider
392dc695ef Merge branch 'fork/Jackpkn/fix/gym-mode-state-persistence-riverpod' into feature/flexible-routines
# Conflicts:
#	lib/widgets/routines/forms.dart
#	lib/widgets/routines/gym_mode.dart
2025-01-18 12:28:02 +01:00
sangharshdeveloper
06ca72e0f8 #687 enhancement theme-customization 2025-01-17 22:19:54 +05:30
sangharshdeveloper
ced268660b #687 enhancement theme-customization 2025-01-12 20:48:31 +05:30
Roland Geider
5a39c6c229 Rename some functions, a bit of cleanup 2025-01-10 15:52:26 +01:00
Roland Geider
5f89ab4b6f Add missing max fields to the slot entry form 2025-01-06 20:28:14 +01:00
Jackpkn
fd1ee4295c fix: improve Gym Mode navigation and state persistence 2025-01-06 21:38:33 +05:30
Roland Geider
1ad59486c2 Start implementing the expanded mode on the slot entry form 2025-01-05 22:49:00 +01:00
Roland Geider
b66aa7444d Some polishing, adding missing fields and other QoL 2025-01-05 19:45:02 +01:00
Roland Geider
ad5d1be306 Pass the necessary IDs to the gym mode and load the rest of the data 2025-01-05 16:35:16 +01:00
Roland Geider
ae4d2230b9 WIP: Make gym mode display the exercises 2025-01-05 14:49:34 +01:00
Roland Geider
f6bae10b9b Merge branch 'master' into feature/flexible-routines
# Conflicts:
#	android/app/build.gradle
#	lib/l10n/app_ta.arb
#	lib/widgets/measurements/charts.dart
#	macos/Podfile.lock
#	pubspec.lock
#	pubspec.yaml
2025-01-05 01:47:54 +01:00
Roland Geider
d35ff240a7 Update/fix android configuration
It seems some packages that have not been updated in some years are causing
problems. android_metadata has been removed here, but flutter_barcode_scanner
is still needed
2024-12-12 20:49:24 +01:00