[consulting] is ACL /CRUD based on multiple values with a ANDclause possible?

Christopher Smith chris.smith at edutech.mobi
Thu Feb 3 10:31:13 UTC 2011


Vince,

Moodle does this out of the box...
http://moodle.org/

C.
  ----- Original Message ----- 
  From: vincew 
  To: consulting at drupal.org 
  Sent: Thursday, February 03, 2011 9:35 AM
  Subject: [consulting] is ACL /CRUD based on multiple values with a ANDclause possible?


  LS,

  I'm preparing a next drupal project and I'm having some requirements
  regarding ACL/CRUD. I'll elaborate what I would like to achieve with a
  small use-case. I've taken this use-case into the realm of education,
  but it's also applicable on several other realms (business for instance
  with organisation/proces groups).

  (btw: I've created a support request for in the OG module queue at
  jan-20, but there wasn't a reaction. Perhaps it wasn't the correct
  place, so I give it a try here. The support request can be found at:
  http://drupal.org/node/1033584



  There is a contenttype called: Evaluation. An evaluation has 2 fields:
  - Location
  - Course

  Users of the system can have different roles:
  - administration
  - teacher
  - student

  Users can be related to zero or more Locations and Courses

  What I would like to have is ACL/CRUD based on the relationship of the
  fields. For instance in a way that a post of an Evaluation with the
  fields: 
  - Amsterdam 
  - Math

  can be CRUD only by users related to both of the field values AND who
  have the correct permission to do so.

  so
  - a user in the role of administration for Amsterdam/Math can Create an
  Evaluation for Amsterdam/Math
  - a user student for Amsterdam/Math can Read an Evaluation
  - a teacher for Amsterdam/Math can Edit an Evaluation

  - a teacher for Amsterdam/Math can view all Evaluations of Amsterdam
  AND/OR all Evaluations for Math

  but:
  - a student for Berlin/Math or Amsterdam/Music can't view the evaluation


  What I would like to know is:

       1. Can this be done with OG?
       2. If not, is there an existing sub module for this concept?
       3. If it can be done with OG, can anyone point me in the direction
          of setting this up? (any OG (submodule) settings and/or
          og_access_hooks or so)
       4. Should I define my own content_type_course module where I can
          specify the CRUD access rules and are there any caveats to this

  Tnx for reading (and answering) this.

  Best,
  VinceW

  -- 

  --------------------------------
  European Information Solutions
  --------------------------------

  T       : +31 412 474015
  F       : +31 412 475194
  M       : +31 630 115252
  Email   : info at eurinsol.eu
  Website : http://www.eurinsol.eu

  --------------------------------
  Your Information Matters
  -------------------------------- 




  _______________________________________________
  consulting mailing list
  consulting at drupal.org
  http://lists.drupal.org/mailman/listinfo/consulting
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/consulting/attachments/20110203/68e6df9f/attachment-0001.html 


More information about the consulting mailing list