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

Last change on this file since 202 was 199, checked in by gav, 15 years ago

Upgrade quartz plugin to 0.4.1 propper.
Refactor and enable quartz scheduling for recurring tasks.
Adjust svn ignores to ignore all log files.
Create a pseudo system person for automated insertions.

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