bruin-tennis-consulting / match-manager

A web app for custom tennis match playback, allowing coaches to easily filter and search points by attributes for film review.
https://match-viewing-dashboard.web.app
8 stars 8 forks source link

Update match upload page #182

Open awest25 opened 2 months ago

awest25 commented 2 months ago

Use react-jsonschema-form to generate an upload form dynamically, to be used internally. Keep in mind that as our needs evolve, we may have to change the shema. Go ahead and add a hidden property to the upload form that always returns its version to be uplaoded with the match, starting with v1 for this. So if we change a field in the schema, we'll also change the version field. in uploadMatch.js:

  1. Put the schema in a different file.

  2. Each account has access to a set of collections. For example, "uclamens" has access to the collections [UCLA(M)]. "taggingTeam" has access to [UCLA(M), UCLA(W), BruinClubTennis, ... ]. So when you're upload a form, it allows you to choose a collection to upload to.

  3. When selecting a team, the list of players from that team should populate.

  4. Write a script that is used to iterate over all matches in firebase and add version = "0"

  5. Upload a test match (it can be a reupload of a different match)

  6. Add a searchableProperties field hardcoded in the upload form (similar to the version) that will list all of the properties that have searchable metadata (basically all but points). (mentioned in #181 )

Note

This may break a lot of things in the site. For example, match names are hardcoded right now but they shoudl be generated dynamically #100 #113 . Please fix as many of these as you can. Off the top of my head, an easy way to fix is to check the schma version, and impliment the stuff that's missing.

see comment below

awest25 commented 2 months ago

(2) is done.

The logic for (3) isn't currently working.