I'm having problems with designing the layout of part of a database. Any help would be great. Tables: users & reports
Users can be admin, coordinator, team_lead or reviewer (admin_level 1-4)
After creating a report, I want to be able to assign users to be an admin, coordinator, team_lead or reviewer to any report. They can be assigned to multiple reports as well. I also need to be able to add or remove these users from their assigned reports.
What's the best way to design this database? Should I have tables for each admin_level? I have thought about adding a record to the reports table with their information each time they're assigned, etc. I keep making it halfway, but then run into issues.
What I've attempted so far...
Inserted a new record into reports table each time someone is assigned to it, with their respective admin_level, but then when I go to assign another user, I want to retrieve all from users table with respective admin_level and also display those that are selected with a checkbox. That would call for updating the records whether they were turned on/off and that's giving me headaches. Assigning the users with a checkbox array hasn't been an issue, but I need to research how to update the records if they are already selected and then turned off while going through the checkbox array after clicking Submit.
There are other things as well, but I've rambled on long enough. Thanks