Changes between Version 21 and Version 22 of DeveloperGuidelinesNewModule


Ignore:
Timestamp:
02/14/09 18:40:40 (13 years ago)
Author:
Fran Boon
Comment:

Add Module to Model so that it appears when DB created, not just this copy of the DB

Legend:

Unmodified
Added
Removed
Modified
  • DeveloperGuidelinesNewModule

    v21 v22  
    77
    88=== Model ===
    9 Add module to db.module:
    10  * http://127.0.0.1:8000/sahana/appadmin/select/db?query=db.s3_module.id%3E0
     9Add module to db.s3_module:
     10 * {{{/models/__db.py}}}
     11{{{
     12# Populate table with Default modules
     13if not len(db().select(db[table].ALL)):
     14    db[table].insert(
     15        name="veh",
     16        name_nice="Vehicle Management System",
     17        priority=16,
     18        description="Allows the management of vehicles",
     19        enabled='True'
     20        )
     21}}}
     22 * Now stop the Web2Py instance.
     23 * Delete the database: {{{/databases/*_s3_module.table}}}
     24 * Restart the Web2Py instance.
    1125
    12 This makes it visible on the front page & the left-hand navigation menu
     26This makes the new module visible on the front page & the left-hand navigation menu.
    1327
    1428Create a file {{{/models/module.py}}}