Only admins should have access to this site.
Authorization is still a work in progress so this might be something to come back to....
Admin creates a fantasy league on the site based off a sport. A fantasy league is the main grouping for users to create and access their fantasy team.
The admin must assign the following values:
Season - The user sees the list of possible seasons based off of the sport that is selected. Example “2019 NHL Playoffs”
Commissioner - Defines the user id that is the commissioner of the league.
League Name - The name of the league
The admin hits a button to create the league which populates the database and defines the authorization data to promote the commissioner user ID is the commissioner of the league.
Now the commissioner is navigated to defining the rules.
Creating a team works but has race a condition that needs to be fixed. The redirect to the page to set the lineup happens before the graphql mutation completes and throws a console error.
Only admins should have access to this site. Authorization is still a work in progress so this might be something to come back to....
Admin creates a fantasy league on the site based off a sport. A fantasy league is the main grouping for users to create and access their fantasy team. The admin must assign the following values:
Mutation: mutation ($user: UserInput!){ updateUser(user: $user) { id success message } } Variable: "league": { "name": "League name", "seasonId": 2, "commissionerId": 1 }