Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

How to best implement data level access 19 Feb 2013 02:08 #6814

  • rnevins
  • rnevins's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 24
  • Thank you received: 6
Hi,

I am still learning how to best develop Joomla components and have found the Cook component generator to be a great way to create components. I have a question about how to best implement a data level access security within a component I'm developing and was hoping someone might give me some guidance.

My situation is as follows:

I am developing a Ride Leader Scheduling System for a bicycle club. There are a number of different regular "rides" that are managed by "coordinators". So I have a Ride table with all the attributes of the particular ride (such as pace, ride start point, etc.) as well as the coordinator name.

There are authorized Ride Leaders for the various rides but these are managed by the Ride Coordinators. So Ride "A" might have a list of 10 Ride Leaders and ride "B" might have another list of 10 Ride Leaders. There can be overlap so it is a many-to-many relationship. Multiple authorized Ride Leaders per ride and any given Ride Leader might be authorized for multiple Rides.

The Leaders and Coordinators are all Joomla users.

I have defined a "leaders" table with the Leader name and the Ride that leader is authorized for. If a leader is authorized for multiple rides then there would just be mulitple rows in the table - so neither the leader nor the ride is a unique value in this table.

My question is this - is there a way using the Cook and Joomla configuration to set it up so coordinators can only add, delete, edit leaders for the rides that they are the coordinator for? So for example, the coordinator for Ride A couldn't add or delete a leader in the leader table for Ride B.

I'm confident I can custom code the logic to do this, but it would be preferable to do it without customization if that is possible.

Thanks in advance and I hope this makes sense.

Rick

Please Log in or Create an account to join the conversation.

Last edit: by rnevins.
  • Page:
  • 1
Time to create page: 0.338 seconds

Freakin' Awesome!!! J-Cook is simply awesome - whether you're a highly experienced developer or complete novice whether you're building a small inventory component or a complete community solution! The beauty comes from a fast slick and reliable platform that readily provides developers with everything they'll need to build the backbone of a solid and secure component with wizards for authoring access publishing aliasing created/modified by dates... you name it COOK provides it! J-Cook really surpasses all of the 'competition' as far as MVC tools are concerned! Try love it and get cooking!
learnthrusong (JED)
          

Get Started