Adds Support for multiple trackers on the main page.#37
Closed
Doonut wants to merge 4 commits into
Closed
Conversation
Contributor
Author
| pub date_to: NaiveDateTime, | ||
| } | ||
|
|
||
| fn parse_query_string( |
Contributor
There was a problem hiding this comment.
we shouldn't need to parse the query manually. I had some issues sending arrays as queries. Instead, either use another lib to deserialize the query, or use a POST request with a json body which is more robust
| let user_stats_reduced = UserProfileVec::from_vec(user_stats); | ||
| .find_user_stats(&query.indexer_ids, &query.date_from, &query.date_to) | ||
| .await | ||
| .map_err(|e| { |
Contributor
There was a problem hiding this comment.
we can just use ? to propagate the error
Contributor
|
done with 9c016af since I didn't get a reply from you, I decided to do it myself. However, feel free to submit other PRs in the future, I'll try to not miss them next time! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hey, I know this is a HUGE commit. I definitely took some guesses on what you would like with the project or not.
Refactor user stats to support multiple indexers and update tracker colors
This PR refactors the user stats API to support multiple indexers simultaneously and updates tracker colors to match actual brand colors. I did guess on some as I don't have access to every supported tracker.
Multi-Indexer Support
Changed from single indexer to multi-indexer format:
UserProfileVecfor one indexerRecord<number, UserProfileVec>where each key is an indexer IDThe frontend components were updated to iterate over multiple indexers using
Object.entries(), allowing charts to display data from multiple trackers simultaneously. Each tracker is now rendered with its own dataset and brand color.Tracker Colors
trackerColors.tswith a mapping of tracker names to their brand colorsImpact