Hi
I'm trying to work out how to structure a multi-user/multi-section admin and it's a bit of a puzzle
Here's the set-up I need :
There are two types of Admin : superadmin and admin - the superadmin has access to all but the normal admins are limited to what they can see - and it's the superadmin who sets the permissions
The site has 5 dynamic sections (this doen't change) and inside each section there are a variable number of subsections that are managed by the superadmin
so, the normal admins can have access to one or several subsections.
At first I thought of just having a page with a vertical list of all subsections with a checkbox for each one and then having a table in the db that stores pairs of admin_id<->subsection_id to state which subsections each admin can access.
The problem with this is when an admin needs to have access to all of the subsections in a section - the superadmin could just click all the checkboxes in that section - this would give the admin access to all existing subsections in that section
but if the superadmin adds a subsection he'd have to manually go through all the admins clicking the checkbox for that subsection
so what i need i some way of having a indicator of partial or total access to each section for each admin - but i really can't figure out how to fit it into the structure
is my only option having another db table that displays partial/total access to each section ? Then if the access is partial it would query the admin_id<->subsection_id table to see which individual subsections they can access ?
any help or pointers on the best and simplest way to structure this would be welcome
thanks