source: trunk/grails-app/conf/BootStrap.groovy @ 254

Last change on this file since 254 was 230, checked in by gav, 15 years ago

Add startup log to BootStrap.
Add help balloon messages to create entry view.

File size: 831 bytes
Line 
1import grails.util.GrailsUtil
2
3class BootStrap
4{
5    def createDataService
6
7    def init = { servletContext ->
8
9        log.info "Application starting."
10        log.debug "GrailsUtil.environment = ${GrailsUtil.environment}"
11
12        switch (GrailsUtil.environment)
13        {
14            case "development":
15                        createDataService.ensureSystemAndAdminAccess()
16                        createDataService.createBaseData()
17                        createDataService.createDemoData()
18                        break
19            case "test":
20                        createDataService.ensureSystemAndAdminAccess()
21                        break
22            case "production":
23                        createDataService.ensureSystemAndAdminAccess()
24                        break 
25        }
26
27    }
28
29    def destroy = {
30    }
31}
Note: See TracBrowser for help on using the repository browser.