I am building a Django app which can be used by multiple companies. Now I have set up the common(super) admin, which can look every users and model. I am storing all the company details on the company table.
Suppose we've 3 companies - A, B and C. I want to create 3 sub-admins for each company, where they can only see/edit all the data related to their company users only.
What I've tried already: I created permissions based on the models but they're not solving the purpose of accessing data from the only single company.
Can anyone explain to me how this can be achieved? Either programmatically or from the admin portal.
Tech Specs:
Django 2.1
Python 3.6.4
PS: If you need more information, then please let me know. I will provide as much information as I can. Thank you.