Fields
Fields are specified as class attributes - static properties. Be careful not to choose field names that conflict with the models API like save, create or delete.
Example:
#
Field typesEach field in your model should be an instance of the appropriate Field class. Djorm uses the field class types to determine quite a few things:
- The column type which tells the database what kind of data to store (e.g. INTEGER,VARCHAR,TEXT)
- The type validations
#
Field optionsEach field takes a certain set of field-specific properties. For example CharField requires maxLength.