freeCodeCamp / freeCodeCamp/classroom

Bug: Classrooms can be created with no certifications

Open
#551 2 comments 0 reactions 0 assignees View on GitHub
bug good first issue
Dominant language
JavaScript
Stars
155
Forks
138
PR merge metrics
No merged PRs in 30d

Description

Currently, it is possible to create a classroom without any certifications. This results in empty classroom pages being created, which would be confusing for teachers.

**Classroom page with no certifications:**
Image

**Desired solution:**
When a teacher is creating a class, the "Create" button should be disabled when there are no certifications selected. If the teacher hovers over the "Create" button, hover text will appear saying, "Please select a certification."
Image

Steps to reproduce the issue:
1. Make sure you can successfully log in via Github (use the Github sign-in option, not Auth0)
2. Run "npx prisma studio" in the terminal, navigate to the "Users" table, change the role of your user to "TEACHER"
3. Make sure you click "Save changes" in prisma studio
4. Sign out of the Classroom app and then sign back in
5. Press the "Classes" button on the top navbar
6. Create a class without selecting a certification

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.