Jump to content

Layers of access to data


Peter Knowles
 Share

This topic is 5763 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I've been trying to wrap my mind around a way to serve a variety of information to different audiences based on their status, and figure it must be a common procedure, so someone out there has it figured out. If so, I'd love to know how best to give different groups access to different records. Here's what I want to do:

In our school's calendar database some events are primarily for staff, some are for staff & students (basically, the school community) and some are for everyone (general public, staff & students). Currently, when the records are created they're coded in the "audience" field as "staff", "students", or "general". However, when searching for staff items, results have to include all three levels; when searching for students, they need to include two levels, and when searching for public, they need to include only the "public" category.

That last one I can handle; it's the others that I'm struggling with. Should I assign numerical point values to each group, and search by some summary field? Or should I structure the hyperlink search tag differently (instead of audience.eq.staff, do something else). There seems to be a problem getting the db to serve subsets of the main category, or something. I have a sense there must be an easy and smart (and, probably, painfully obvious?) way to approach this. Any ideas?

Thanks in advance.

Link to comment
Share on other sites

Thanks Garry.

I am using CDML tags (in Dreamweaver-created pages) if that makes a difference.

So you think stucturing the search request using [FMP-IF], [FMP-ELSE] tags in a nested arrangement is what I need to do? (from the CDML/Web page side, rather than creating a separate field that performs the same function?

BTW: Can you nest if/else arguments? I didn't think you could.

Peter

Link to comment
Share on other sites

I'm assuming that you have some kind of User table that is queried before the events are displayed. The returned Format file can contain the following:

[FMP-If: user_type .eq. staff]

[FMP-InlineAction: ....findall....] ... [/FMP-InlineAction]

[FMP-ElseIf: user_type .eq. student]

[FMP-InlineAction: event_type <> staff] ... [/FMP-InlineAction]

[FMP-Else]

[FMP-InlineAction: event_type == public] ... [/FMP-InlineAction]

[/FMP-If]

All the best.

Garry

Link to comment
Share on other sites

This topic is 5763 days old. Please don't post here. Open a new topic instead.

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.