Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Train View: Improved the selection of workouts #4400

Conversation

thejockl
Copy link
Contributor

@thejockl thejockl commented Sep 23, 2023

This PR tries to provide a solution for #411

It introduces a new schema for the TrainDB, filters for workouts and an info-widget in the TrainSideBar. Workouts can be rated and tagged.
The filter works on selected metrics of the workout as well as the description and all assigned tags.
As soon as the zones / CP of an athlete change, the TrainDB is automatically updated.
A manager to add / remove tags was added to the Train settings.

Additionally the change includes refactorings to improve type safety (converted some enums to C++11 enum class) and Extracted pure data baseclasses from ErgFile and VideoSyncFile to achieve faster turnaround times by developing outside GoldenCheetah.

Example for a filter: "duration 1:00..1:15, variability 1.1..1.2, dominantzone z4, stress 80.., rating 3..4"

This PR is the replacement for #4398 after cleaning up the commit-history and realizing Marcs first comments:

  • The contents of the folders Train/info and Train filter were moved into Train
  • Removed a proprietary definition working only in GNU Bison
  • Removed some debug-statements in TrainDB.cpp
  • Changed the license of tags (100% authored by me) from BSD to GPLv2 and moved the code from contrib/tags to Train

Additional remarks:

amtriathlon and others added 25 commits April 1, 2023 09:47
Just a few changes from RC4:
- Updated German, Italian and Spanish translations
- Better contrast in Athlete Tabs when using dark colors
- Better contrast for selected items in Trends/Train sidebar
  when using dark colors
- Clarify texts in Relative Wattage Workout Creator
[Publish Binaries]
@liversedge
Copy link
Member

When its ready for commit let me know and will review with a view to pull

@thejockl
Copy link
Contributor Author

thejockl commented Oct 3, 2023

All issues I gathered from the users-list are resolved, so I would be happy if you could start the review

@amtriathlon
Copy link
Member

Hi Joachim, I fixed a conflict due to a merged PR from another contributor and added a little fix for Qt6 compatibility, current conflict is with your own PR, so you will have a better idea about how to fix it.
I started to look at the code and didn't understand the need to introduce the ErgFileBase class, considering ErgFile base is still a monolithic clase handling all different modes and file formats, and not a set of subclases, am I missing something?

@thejockl
Copy link
Contributor Author

thejockl commented Apr 27, 2024

Hi Ale, happy to see you looking into this PR!

I just merged master into this branch, resolving all conflicts.

The reason for the *Base-classes (I honestly dislike the name but couldn't come up with something better) is that this helped me developing most of the code in a small testdriver outside Golden Cheetah, giving the following benefits:

  • Reduced compile times
  • Reduced startup times
  • No navigation required to reach the functionality under development
  • Showing the full models in a table, a great help while developing the display-widgets and filtering (why don't I find this workout?)

By that I had way faster turnaround times, and could better concentrate on the features.

@thejockl
Copy link
Contributor Author

thejockl commented May 7, 2024

As I experienced a crash related to auto completion when running with Qt6, please wait for a fix before further proceeding

@thejockl
Copy link
Contributor Author

thejockl commented May 9, 2024

The crash has been fixed

@amtriathlon amtriathlon added this to the 3.7 milestone May 20, 2024
@amtriathlon amtriathlon merged commit 77df5b3 into GoldenCheetah:master May 20, 2024
1 check passed
@amtriathlon
Copy link
Member

This is a very nice feature, Joaquim, thank you very much!

We will need to update the wiki for v3.7 in two places: https://github.com/GoldenCheetah/GoldenCheetah/wiki/UG_Side-Bar_Train-view and https://github.com/GoldenCheetah/GoldenCheetah/wiki/UG_Special-Topics_Workouts%2C-Media-and-VideoSync-Library

@thejockl
Copy link
Contributor Author

Hi @amtriathlon, thanks so much for taking care and merging, I highly appreciate all your efforts!

I will look into the Wiki and come up with proposals, probably on the dev-list

amtriathlon added a commit that referenced this pull request May 26, 2024
2ac2cd6 Batch Processing addition metadata update (#4399)
9647975 Fix isSpecial(internalName) in SpecialFields
e41e6b6 Fit: Add FIELD_87 for record (cycle_length16) fix #4489
c088aaf Fixes the background colour of the group by sub menu (#4492)
06a6dbe Fix copy paste error preventing macOS build
5e3db39 Add delete button to manage filters (#4493)
77df5b3 Train View: Improved the selection of workouts (#4400)
cfb8c2f Manage Perspectives - perspectives list cosmetics
f1bb83f Update Images default chart
562ef17 Update Spanish translation (#4487)
57c11e0 Remove Ctrl+A shortcut for Add Cloud Account
cf2e8d8 Enable translation of Save Changes in SaveExitDialog
1b49890 Update German Translation
f97770f GC CSV Export - rcad instead of cad for runs
7a11a6a Initializing AllPlot::isPanning to false (#4482)
76dedfb Fix Average Speed aggregation
6299374 Images chart update on image drop and import
fdb6d17 Python Web Chart - Don't accept drops
68ad048 Update Images Python chart in default layout
2d8bdd7 FitRideFile - Decode GAP extra field in m/s
5073ba8 Add Images chart to default layout
c693ed6 FitRideFile - Extra fields 136, 143 and 144
4f5a0eb CP Chart - show/hide interval settings based on model and
fitting selection (#4382)
0b144cc Train View: Coloring by powerzones in ErgFilePlot (#4479)
02835e3 Added support for old Daum devices before 2001 (#4303)
71c72d6 Changed the standard colors for compare-mode (#4478)
118eafe FitRideFile : A devApp can replace another with same local id
1241c0a Use elapsed time for session (instead of timestamp) fix #4474
a1a76fb WorkoutWizard - Don't save and close on Cancel
64c7ce3 Improved search/filter box drop down menu icon (#4470)
[publish binaries]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants