I have a site built in codeigniter for which I have designed an access control list to manage permissions of different types of users. Various users logged in to site are :
- Super Admin
- Admin
- SEO User
- Developer
Now I have completed the Access Control for this and permission for add, update, list and delete can be assigned to every user through a module accessible to Super Admin.
Now (this is a part of client's new requirement) I want to make the columns accessible to certain users, Eg:
If a table Products has 4 Columns
Products :
id | Products | Price | Status
-----+-----------+-------+----------
1 | prod1 | 20.0 | 1
2 | prod2 | 35.6 | 0
Now I want that for SEO Users Column Price does Not show up during the Listing.
NOTE : this is just an example, I need to make this dynamic so admin controls who has permission to which column. I cannot simply write If Else logic in my View File to exclude Unwanted columns.
Please Tell me how I can do this without redesign the whole system or making very major changes.