Tino Posted September 8, 2022 Share Posted September 8, 2022 Hi, I'm working on a dashboard with some functionality that will be used by two roles "user" and "management". These both roles should not see anything else in the admin-header-section than the dashboard, like in this screenshot. Also while editing any elements they should not see "Settings" Delete and so on like seen here: All these options should only appear for the "superuser" or "developer" for maintaining everything. For the moment it would be ok if the options would be just "not visible" in the longterm it would be awesome to find a way to really block every user not in the specific role. In my actual case the users would not try to hack something but everybody know to better be safe than sorry ? Maybe it is related to that topic also: I noticed if I put all fields of a template in a "FieldsetTabOpen" the "Content"-Tab is still shown and have some wired actions (after switching to an other tab and back it shows the content of the former tab). It would be no problem to completely remove that "Content"-Tab at all by a hook and only work with "FieldsetTabOpen". I hope I could somehow explain what I would like to archive. Thank you all 1 Link to comment Share on other sites More sharing options...
flydev Posted September 9, 2022 Share Posted September 9, 2022 (edited) But role is a thing, and permissions is another and this last is what you are looking for. Look there - https://processwire.com/docs/user-access/permissions/ - and try to play with them, then give a look at those modules : https://processwire.com/modules/admin-restrict-page-tree/ https://processwire.com/modules/custom-admin-menus/ For example, I have a role "accountant" and he do not have access to the page tree or any other features than the "accounting" module. Edited September 9, 2022 by flydev ?? modules 4 Link to comment Share on other sites More sharing options...
Tino Posted September 10, 2022 Author Share Posted September 10, 2022 Thank you for the hint with the modules also. If I just use the AdminRestrictPageTree module it also hides my self created dashboard. But I created the Dashboard by myself and not with the module mentioned in your answer. I will give that a try also. And of course you were totally right and I‘m sorry for my bad wording here. Yes I was talking about permissions and not roles. I will play around and also have a look inside the mentioned modules to maybe get some ideas out of the code. Thank you 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now