Changes between Version 55 and Version 56 of S3/S3AAA/OrgAuth


Ignore:
Timestamp:
10/04/12 13:43:37 (12 years ago)
Author:
Dominic König
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • S3/S3AAA/OrgAuth

    v55 v56  
    4343=== Realms ===
    4444
    45 The '''realm''' of a person entity is the set of all records controlled ("owned") by this entity (="their data").  The realm which a particular record belongs to is encoded as person entity ID (pe_id) in the {{{realm_entity}}} field in this record. The "realm_entity" field - if present in the table - gets automatically populated in CRUD and Imports (during create), using the auth.s3_set_record_owner method.
     45The '''realm''' of a person entity is the set of all records controlled ("owned") by this entity (="their data").  The realm which a particular record belongs to is encoded as person entity ID (pe_id) in the {{{realm_entity}}} field in this record. The "realm_entity" field - if present in the table - gets automatically populated in CRUD and Imports (during create), using the auth.s3_set_record_owner method.
     46
     47Where the realm entity can be determined from the record itself, you may wish it to be updated along with changes in the record. In this case, you can set the '''update_realm''' setting for the table to {{{True}}}:
     48
     49{{{
     50    s3db.configure(tablename,
     51                   update_realm=True)
     52}}}
     53
     54Realm entity updates will propagate to all components listed under the '''realm_components''' setting:
     55
     56{{{
     57    s3db.configure(tablename,
     58                   update_realm=True,
     59                   realm_components=["abc", "xyz"])
     60}}}
    4661
    4762The entity whose realm a record will belong to will be calculate according to the following (in order of decreasing priority):