Edgewall Software

Version 1 (modified by jeoffwilks@…, 19 years ago) ( diff )

Taken from a list email by Matthew Good on 10/12/2005

Trac Data Models

The main models that developers might be interested in are Ticket and WikiPage. The constructors each take the environment as the first parameter, and the ticket id or wiki page name next.

Ticket

Data Model - trac.ticket.model.Ticket

29      class Ticket(object):
30      
31          def __init__(self, env, tkt_id=None, db=None):

For usage examples, see trac.ticket.web_ui.

WikiPage

Data Model - trac.wiki.model.WikiPage

26      class WikiPage(object):
27          """Represents a wiki page (new or existing)."""
28      
29          def __init__(self, env, name=None, version=None, db=None):

The WikiPage has an optional parameter for the version, and you probably won't need to bother with the last parameter which is an optional db connection.

For usage examples, see trac.wiki.web_ui.

Note: See TracWiki for help on using the wiki.