Mercurial > p > roundup > code
comparison roundup/templates/classic/dbinit.py @ 825:0779ea9f1f18
More indexer work:
- all String properties may now be indexed too. Currently there's a bit of
"issue" specific code in the actual searching which needs to be
addressed. In a nutshell:
+ pass 'indexme="yes"' as a String() property initialisation arg, eg:
file = FileClass(db, "file", name=String(), type=String(),
comment=String(indexme="yes"))
+ the comment will then be indexed and be searchable, with the results
related back to the issue that the file is linked to
- as a result of this work, the FileClass has a default MIME type that may
be overridden in a subclass, or by the use of a "type" property as is
done in the default templates.
- the regeneration of the indexes (if necessary) is done once the schema is
set up in the dbinit.
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Tue, 09 Jul 2002 03:02:53 +0000 |
| parents | 2e70123bbf5a |
| children | 2dd862af72ee |
comparison
equal
deleted
inserted
replaced
| 824:34eacaa7e313 | 825:0779ea9f1f18 |
|---|---|
| 13 # BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | 13 # BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS |
| 14 # FOR A PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" | 14 # FOR A PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" |
| 15 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, | 15 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, |
| 16 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. | 16 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
| 17 # | 17 # |
| 18 # $Id: dbinit.py,v 1.17 2002-05-24 04:03:23 richard Exp $ | 18 # $Id: dbinit.py,v 1.18 2002-07-09 03:02:53 richard Exp $ |
| 19 | 19 |
| 20 import os | 20 import os |
| 21 | 21 |
| 22 import instance_config | 22 import instance_config |
| 23 from roundup import roundupdb | 23 from roundup import roundupdb |
| 99 priority=Link("priority"), status=Link("status")) | 99 priority=Link("priority"), status=Link("status")) |
| 100 | 100 |
| 101 import detectors | 101 import detectors |
| 102 detectors.init(db) | 102 detectors.init(db) |
| 103 | 103 |
| 104 # schema is set up - run any post-initialisation | |
| 105 db.post_init() | |
| 104 return db | 106 return db |
| 105 | 107 |
| 106 def init(adminpw): | 108 def init(adminpw): |
| 107 ''' as from the roundupdb method initDB | 109 ''' as from the roundupdb method initDB |
| 108 | 110 |
| 139 address=instance_config.ADMIN_EMAIL) | 141 address=instance_config.ADMIN_EMAIL) |
| 140 db.commit() | 142 db.commit() |
| 141 | 143 |
| 142 # | 144 # |
| 143 # $Log: not supported by cvs2svn $ | 145 # $Log: not supported by cvs2svn $ |
| 146 # Revision 1.17 2002/05/24 04:03:23 richard | |
| 147 # Added commentage to the dbinit files to help people with their | |
| 148 # customisation. | |
| 149 # | |
| 144 # Revision 1.16 2002/02/16 08:06:14 richard | 150 # Revision 1.16 2002/02/16 08:06:14 richard |
| 145 # Removed the key property restriction on title of the classic issue class. | 151 # Removed the key property restriction on title of the classic issue class. |
| 146 # | 152 # |
| 147 # Revision 1.15 2002/02/15 07:08:44 richard | 153 # Revision 1.15 2002/02/15 07:08:44 richard |
| 148 # . Alternate email addresses are now available for users. See the MIGRATION | 154 # . Alternate email addresses are now available for users. See the MIGRATION |
