Mercurial > p > roundup > code
diff doc/customizing.txt @ 2153:643f9c9d7517
*** empty log message ***
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Sat, 27 Mar 2004 00:12:11 +0000 |
| parents | 702f9a6afdcf |
| children | 9f6e6bc40a08 |
line wrap: on
line diff
--- a/doc/customizing.txt Sat Mar 27 00:01:48 2004 +0000 +++ b/doc/customizing.txt Sat Mar 27 00:12:11 2004 +0000 @@ -2,7 +2,7 @@ Customising Roundup =================== -:Version: $Revision: 1.126 $ +:Version: $Revision: 1.127 $ .. This document borrows from the ZopeBook section on ZPT. The original is at: http://www.zope.org/Documentation/Books/ZopeBook/current/ZPT.stx @@ -317,7 +317,30 @@ A tracker schema defines what data is stored in the tracker's database. Schemas are defined using Python code in the ``dbinit.py`` module of your -tracker. The "classic" schema looks like this (see below for the meaning +tracker. + +The ``dbinit.py`` module +------------------------ + +The ``dbinit.py`` module contains two functions: + +**open** + This function defines what your tracker looks like on the inside, the + **schema** of the tracker. It defines the **Classes** and **properties** + on each class. It also defines the **security** for those Classes. The + next few sections describe how schemas work and what you can do with + them. +**init** + This function is responsible for setting up the initial state of your + tracker. It's called exactly once - but the ``roundup-admin initialise`` + command. See the start of the section on `database content`_ for more + info about how this works. + + +The "classic" schema +-------------------- + +The "classic" schema looks like this (see below for the meaning of ``'setkey'``):: pri = Class(db, "priority", name=String(), order=String())
