Can it do this?

4 posts by 2 authors in: Forums > CMS Builder
Last Post: January 18, 2008   (RSS)

By inventive - January 18, 2008

Can I restrict the access to fields based on the user or user group? This would be in situations where I would want a group of users to access the entire section/database and a different group limited to specific fields within the same section.

Thanks

Re: [inventive] Can it do this?

By Dave - January 18, 2008

No, it can't do that yet.

The current level of access control is you can grant or deny full access to a section on a per user basis. You can mark fields as adminOnly, meaning only admins can view or modify those fields. There also is no user groups, just users.

I can put that on the feature request list, if you like though.

The only other option would be that if you were comfortable with PHP you could modify the code and hardcode it to not show fields for certain users. If you wanted to give that a shot I'd be happy to assist. We should be able to determine pretty quickly if it's enough for what you need or not.
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Can it do this?

By inventive - January 18, 2008 - edited: January 18, 2008

Yes, I would like to request a feature with the ability to create user groups and assign a member/user accordingly. The ability to define the groups privileges down to the field level would be nice. If they didn't have the proper privilege then the field would be hidden from their view.

But, so I understand correctly, right now I can limit a users access to specific fields? Is that easily accomplished via the control panel by point and click or does it require a change in the code?

For example, your saying I can create non admin users that have access to 6 of 10 fields but have admins that have access to 10 of 10 fields (all within the same section)?

I didn't notice anything about user management in the docs - am I just missing it?

Thanks

Re: [inventive] Can it do this?

By Dave - January 18, 2008

Ok, I've added that to the feature request list.

There's a option in the field editor right now called "admin only field". If you check that then only users with global admin access can see those fields.

If you want more fine grained controls, there's no easy way to do it, we'd have to hack the code a little.

The way we'd do it is probably to add some checkboxes to the accounts menu (easy to do through the program) they you'd check or uncheck for each user to indicate whether they'd have access to a field or set of fields. That part is all automatic.

Then, in the code that displays the fields, we'd add some code that said "if field is named "X" and user doesn't have checkbox1 checked, don't show that field".

Hope that makes sense. What are the sections and fields do you want to grant/deny access to?
Dave Edis - Senior Developer
interactivetools.com