Changes between Version 44 and Version 45 of DeveloperGuidelinesS3Framework


Ignore:
Timestamp:
09/12/10 10:02:54 (14 years ago)
Author:
Fran Boon
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DeveloperGuidelinesS3Framework

    v44 v45  
    5050}}}
    5151
    52 All tables which are user-editable need to be protected for conflict resolution & synchronization using the predefined reusable fields {{{timestamp}}} & {{{uuidstamp}}}.[[BR]]
    53 These are defined in {{{models/00_tables.py}}}:
    54 {{{
    55 # Reusable timestamp fields
    56 timestamp = SQLTable(None, "timestamp",
    57             Field("created_on", "datetime",
    58                           writable=False,
    59                           default=request.now),
    60             Field("modified_on", "datetime",
    61                           writable=False,
    62                           default=request.now,update=request.now))
    63 
    64 # We need UUIDs as part of database synchronization
    65  import uuid
    66 uuidstamp = SQLTable(None, "uuidstamp",
    67             Field("uuid", length=64,
    68                           writable=False,
    69                           default=uuid.uuid4()))
    70 }}}
    71 
     52All tables which are user-editable need to be protected for conflict resolution & synchronization using the predefined reusable fields {{{timestamp}}} & {{{uuidstamp}}}.
    7253== Optional ==
    7354Other reusable fields are available to add Foreign Key links to key tables, such as 'location_id' to add a GIS location for Mapping, 'person_id' to add a Person & 'organisation_id' to add a link to an Organisation.