AritDevCircle / shiftwork2

Are you a shiftworker looking for last-minute gigs? Or a business owner with open shifts to fill? The Shiftwork app can connect you to shift opportunities or shiftworkers!
https://shiftworkapp.herokuapp.com
2 stars 4 forks source link

Add restrictions to /workers/new action #93

Closed ncbui closed 3 years ago

ncbui commented 3 years ago

What type of PR is this? (check all applicable)

Description of what PR does

The workers/new action now checks that the user has a worker user type and does not have an existing worker account before displaying the Create New Worker form.

Related PRs and/or Issues (if any)

QA Instructions, Screenshots, Recordings

Navigate to 'http://127.0.0.1:3000/workers/new' Worker users that do not have an associated worker account should see the Create New Worker form Org users and workers with existing worker account should be redirected with error message

Added tests?

Added to documentation?