Version 6 (modified by anubhav, 12 years ago) ( diff )




Def setting():

These will be imported into the models so will run before the models and for the first time only The settings layout needs to be stored in here. The settings is a dict with keys as the:



 Settings = {"databse.db_type" : {"nice_name" :T("Database"), 
                                  "description":T("Database Type: "), 
                                  "options":['sqlite', 'sql', 'mysql'],
                                  "jquery_validation_requirements”: "required lettersonly"
             #and similarly other options for language can be set

These are really useful for views as this provide the information regarding input type, the value to select from, the field name and the validation requirement. These layouts are mostly for the views. Some of these like port will also contain a validation field for the range of accepted values.

We will have to set the settings in accordance with modules/s3/

Def modules() : =

These needs to store the names of the modules:-

modules = {
#true meaning "on"

Here the “on” indicate that the default value of the module status is on.

In the modules the layout is not required, as they are stored when we run the modified form of 000_config in the models. The input types of these (name, Description, Access level) are quite fixed so they need not to be stored separately. Therefore not much help is required for the views to.

Note: See TracWiki for help on using the wiki.