Index: trunk/grails-app/controllers/AssemblyController.groovy
===================================================================
--- trunk/grails-app/controllers/AssemblyController.groovy	(revision 118)
+++ trunk/grails-app/controllers/AssemblyController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class AssemblyController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ assemblyInstanceList: Assembly.list( params ), assemblyInstanceTotal: Assembly.count() ]
+    }
+
+    def show = {
+        def assemblyInstance = Assembly.get( params.id )
+
+        if(!assemblyInstance) {
+            flash.message = "Assembly not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ assemblyInstance : assemblyInstance ] }
+    }
+
+    def delete = {
+        def assemblyInstance = Assembly.get( params.id )
+        if(assemblyInstance) {
+            try {
+                assemblyInstance.delete()
+                flash.message = "Assembly ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "Assembly ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "Assembly not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def assemblyInstance = Assembly.get( params.id )
+
+        if(!assemblyInstance) {
+            flash.message = "Assembly not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ assemblyInstance : assemblyInstance ]
+        }
+    }
+
+    def update = {
+        def assemblyInstance = Assembly.get( params.id )
+        if(assemblyInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(assemblyInstance.version > version) {
+                    
+                    assemblyInstance.errors.rejectValue("version", "assembly.optimistic.locking.failure", "Another user has updated this Assembly while you were editing.")
+                    render(view:'edit',model:[assemblyInstance:assemblyInstance])
+                    return
+                }
+            }
+            assemblyInstance.properties = params
+            if(!assemblyInstance.hasErrors() && assemblyInstance.save()) {
+                flash.message = "Assembly ${params.id} updated"
+                redirect(action:show,id:assemblyInstance.id)
+            }
+            else {
+                render(view:'edit',model:[assemblyInstance:assemblyInstance])
+            }
+        }
+        else {
+            flash.message = "Assembly not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def assemblyInstance = new Assembly()
+        assemblyInstance.properties = params
+        return ['assemblyInstance':assemblyInstance]
+    }
+
+    def save = {
+        def assemblyInstance = new Assembly(params)
+        if(!assemblyInstance.hasErrors() && assemblyInstance.save()) {
+            flash.message = "Assembly ${assemblyInstance.id} created"
+            redirect(action:show,id:assemblyInstance.id)
+        }
+        else {
+            render(view:'create',model:[assemblyInstance:assemblyInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/AssetController.groovy
===================================================================
--- trunk/grails-app/controllers/AssetController.groovy	(revision 118)
+++ trunk/grails-app/controllers/AssetController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class AssetController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ assetInstanceList: Asset.list( params ), assetInstanceTotal: Asset.count() ]
+    }
+
+    def show = {
+        def assetInstance = Asset.get( params.id )
+
+        if(!assetInstance) {
+            flash.message = "Asset not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ assetInstance : assetInstance ] }
+    }
+
+    def delete = {
+        def assetInstance = Asset.get( params.id )
+        if(assetInstance) {
+            try {
+                assetInstance.delete()
+                flash.message = "Asset ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "Asset ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "Asset not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def assetInstance = Asset.get( params.id )
+
+        if(!assetInstance) {
+            flash.message = "Asset not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ assetInstance : assetInstance ]
+        }
+    }
+
+    def update = {
+        def assetInstance = Asset.get( params.id )
+        if(assetInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(assetInstance.version > version) {
+                    
+                    assetInstance.errors.rejectValue("version", "asset.optimistic.locking.failure", "Another user has updated this Asset while you were editing.")
+                    render(view:'edit',model:[assetInstance:assetInstance])
+                    return
+                }
+            }
+            assetInstance.properties = params
+            if(!assetInstance.hasErrors() && assetInstance.save()) {
+                flash.message = "Asset ${params.id} updated"
+                redirect(action:show,id:assetInstance.id)
+            }
+            else {
+                render(view:'edit',model:[assetInstance:assetInstance])
+            }
+        }
+        else {
+            flash.message = "Asset not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def assetInstance = new Asset()
+        assetInstance.properties = params
+        return ['assetInstance':assetInstance]
+    }
+
+    def save = {
+        def assetInstance = new Asset(params)
+        if(!assetInstance.hasErrors() && assetInstance.save()) {
+            flash.message = "Asset ${assetInstance.id} created"
+            redirect(action:show,id:assetInstance.id)
+        }
+        else {
+            render(view:'create',model:[assetInstance:assetInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/AssetTypeController.groovy
===================================================================
--- trunk/grails-app/controllers/AssetTypeController.groovy	(revision 118)
+++ trunk/grails-app/controllers/AssetTypeController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class AssetTypeController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ assetTypeInstanceList: AssetType.list( params ), assetTypeInstanceTotal: AssetType.count() ]
+    }
+
+    def show = {
+        def assetTypeInstance = AssetType.get( params.id )
+
+        if(!assetTypeInstance) {
+            flash.message = "AssetType not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ assetTypeInstance : assetTypeInstance ] }
+    }
+
+    def delete = {
+        def assetTypeInstance = AssetType.get( params.id )
+        if(assetTypeInstance) {
+            try {
+                assetTypeInstance.delete()
+                flash.message = "AssetType ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "AssetType ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "AssetType not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def assetTypeInstance = AssetType.get( params.id )
+
+        if(!assetTypeInstance) {
+            flash.message = "AssetType not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ assetTypeInstance : assetTypeInstance ]
+        }
+    }
+
+    def update = {
+        def assetTypeInstance = AssetType.get( params.id )
+        if(assetTypeInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(assetTypeInstance.version > version) {
+                    
+                    assetTypeInstance.errors.rejectValue("version", "assetType.optimistic.locking.failure", "Another user has updated this AssetType while you were editing.")
+                    render(view:'edit',model:[assetTypeInstance:assetTypeInstance])
+                    return
+                }
+            }
+            assetTypeInstance.properties = params
+            if(!assetTypeInstance.hasErrors() && assetTypeInstance.save()) {
+                flash.message = "AssetType ${params.id} updated"
+                redirect(action:show,id:assetTypeInstance.id)
+            }
+            else {
+                render(view:'edit',model:[assetTypeInstance:assetTypeInstance])
+            }
+        }
+        else {
+            flash.message = "AssetType not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def assetTypeInstance = new AssetType()
+        assetTypeInstance.properties = params
+        return ['assetTypeInstance':assetTypeInstance]
+    }
+
+    def save = {
+        def assetTypeInstance = new AssetType(params)
+        if(!assetTypeInstance.hasErrors() && assetTypeInstance.save()) {
+            flash.message = "AssetType ${assetTypeInstance.id} created"
+            redirect(action:show,id:assetTypeInstance.id)
+        }
+        else {
+            render(view:'create',model:[assetTypeInstance:assetTypeInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/ComponentItemController.groovy
===================================================================
--- trunk/grails-app/controllers/ComponentItemController.groovy	(revision 118)
+++ trunk/grails-app/controllers/ComponentItemController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class ComponentItemController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ componentItemInstanceList: ComponentItem.list( params ), componentItemInstanceTotal: ComponentItem.count() ]
+    }
+
+    def show = {
+        def componentItemInstance = ComponentItem.get( params.id )
+
+        if(!componentItemInstance) {
+            flash.message = "ComponentItem not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ componentItemInstance : componentItemInstance ] }
+    }
+
+    def delete = {
+        def componentItemInstance = ComponentItem.get( params.id )
+        if(componentItemInstance) {
+            try {
+                componentItemInstance.delete()
+                flash.message = "ComponentItem ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "ComponentItem ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "ComponentItem not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def componentItemInstance = ComponentItem.get( params.id )
+
+        if(!componentItemInstance) {
+            flash.message = "ComponentItem not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ componentItemInstance : componentItemInstance ]
+        }
+    }
+
+    def update = {
+        def componentItemInstance = ComponentItem.get( params.id )
+        if(componentItemInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(componentItemInstance.version > version) {
+                    
+                    componentItemInstance.errors.rejectValue("version", "componentItem.optimistic.locking.failure", "Another user has updated this ComponentItem while you were editing.")
+                    render(view:'edit',model:[componentItemInstance:componentItemInstance])
+                    return
+                }
+            }
+            componentItemInstance.properties = params
+            if(!componentItemInstance.hasErrors() && componentItemInstance.save()) {
+                flash.message = "ComponentItem ${params.id} updated"
+                redirect(action:show,id:componentItemInstance.id)
+            }
+            else {
+                render(view:'edit',model:[componentItemInstance:componentItemInstance])
+            }
+        }
+        else {
+            flash.message = "ComponentItem not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def componentItemInstance = new ComponentItem()
+        componentItemInstance.properties = params
+        return ['componentItemInstance':componentItemInstance]
+    }
+
+    def save = {
+        def componentItemInstance = new ComponentItem(params)
+        if(!componentItemInstance.hasErrors() && componentItemInstance.save()) {
+            flash.message = "ComponentItem ${componentItemInstance.id} created"
+            redirect(action:show,id:componentItemInstance.id)
+        }
+        else {
+            render(view:'create',model:[componentItemInstance:componentItemInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/FormController.groovy
===================================================================
--- trunk/grails-app/controllers/FormController.groovy	(revision 118)
+++ trunk/grails-app/controllers/FormController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class FormController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ formInstanceList: Form.list( params ), formInstanceTotal: Form.count() ]
+    }
+
+    def show = {
+        def formInstance = Form.get( params.id )
+
+        if(!formInstance) {
+            flash.message = "Form not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ formInstance : formInstance ] }
+    }
+
+    def delete = {
+        def formInstance = Form.get( params.id )
+        if(formInstance) {
+            try {
+                formInstance.delete()
+                flash.message = "Form ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "Form ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "Form not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def formInstance = Form.get( params.id )
+
+        if(!formInstance) {
+            flash.message = "Form not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ formInstance : formInstance ]
+        }
+    }
+
+    def update = {
+        def formInstance = Form.get( params.id )
+        if(formInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(formInstance.version > version) {
+                    
+                    formInstance.errors.rejectValue("version", "form.optimistic.locking.failure", "Another user has updated this Form while you were editing.")
+                    render(view:'edit',model:[formInstance:formInstance])
+                    return
+                }
+            }
+            formInstance.properties = params
+            if(!formInstance.hasErrors() && formInstance.save()) {
+                flash.message = "Form ${params.id} updated"
+                redirect(action:show,id:formInstance.id)
+            }
+            else {
+                render(view:'edit',model:[formInstance:formInstance])
+            }
+        }
+        else {
+            flash.message = "Form not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def formInstance = new Form()
+        formInstance.properties = params
+        return ['formInstance':formInstance]
+    }
+
+    def save = {
+        def formInstance = new Form(params)
+        if(!formInstance.hasErrors() && formInstance.save()) {
+            flash.message = "Form ${formInstance.id} created"
+            redirect(action:show,id:formInstance.id)
+        }
+        else {
+            render(view:'create',model:[formInstance:formInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/FrequencyController.groovy
===================================================================
--- trunk/grails-app/controllers/FrequencyController.groovy	(revision 118)
+++ trunk/grails-app/controllers/FrequencyController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class FrequencyController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ frequencyInstanceList: Frequency.list( params ), frequencyInstanceTotal: Frequency.count() ]
+    }
+
+    def show = {
+        def frequencyInstance = Frequency.get( params.id )
+
+        if(!frequencyInstance) {
+            flash.message = "Frequency not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ frequencyInstance : frequencyInstance ] }
+    }
+
+    def delete = {
+        def frequencyInstance = Frequency.get( params.id )
+        if(frequencyInstance) {
+            try {
+                frequencyInstance.delete()
+                flash.message = "Frequency ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "Frequency ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "Frequency not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def frequencyInstance = Frequency.get( params.id )
+
+        if(!frequencyInstance) {
+            flash.message = "Frequency not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ frequencyInstance : frequencyInstance ]
+        }
+    }
+
+    def update = {
+        def frequencyInstance = Frequency.get( params.id )
+        if(frequencyInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(frequencyInstance.version > version) {
+                    
+                    frequencyInstance.errors.rejectValue("version", "frequency.optimistic.locking.failure", "Another user has updated this Frequency while you were editing.")
+                    render(view:'edit',model:[frequencyInstance:frequencyInstance])
+                    return
+                }
+            }
+            frequencyInstance.properties = params
+            if(!frequencyInstance.hasErrors() && frequencyInstance.save()) {
+                flash.message = "Frequency ${params.id} updated"
+                redirect(action:show,id:frequencyInstance.id)
+            }
+            else {
+                render(view:'edit',model:[frequencyInstance:frequencyInstance])
+            }
+        }
+        else {
+            flash.message = "Frequency not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def frequencyInstance = new Frequency()
+        frequencyInstance.properties = params
+        return ['frequencyInstance':frequencyInstance]
+    }
+
+    def save = {
+        def frequencyInstance = new Frequency(params)
+        if(!frequencyInstance.hasErrors() && frequencyInstance.save()) {
+            flash.message = "Frequency ${frequencyInstance.id} created"
+            redirect(action:show,id:frequencyInstance.id)
+        }
+        else {
+            render(view:'create',model:[frequencyInstance:frequencyInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/LifePlanController.groovy
===================================================================
--- trunk/grails-app/controllers/LifePlanController.groovy	(revision 118)
+++ trunk/grails-app/controllers/LifePlanController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class LifePlanController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ lifePlanInstanceList: LifePlan.list( params ), lifePlanInstanceTotal: LifePlan.count() ]
+    }
+
+    def show = {
+        def lifePlanInstance = LifePlan.get( params.id )
+
+        if(!lifePlanInstance) {
+            flash.message = "LifePlan not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ lifePlanInstance : lifePlanInstance ] }
+    }
+
+    def delete = {
+        def lifePlanInstance = LifePlan.get( params.id )
+        if(lifePlanInstance) {
+            try {
+                lifePlanInstance.delete()
+                flash.message = "LifePlan ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "LifePlan ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "LifePlan not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def lifePlanInstance = LifePlan.get( params.id )
+
+        if(!lifePlanInstance) {
+            flash.message = "LifePlan not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ lifePlanInstance : lifePlanInstance ]
+        }
+    }
+
+    def update = {
+        def lifePlanInstance = LifePlan.get( params.id )
+        if(lifePlanInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(lifePlanInstance.version > version) {
+                    
+                    lifePlanInstance.errors.rejectValue("version", "lifePlan.optimistic.locking.failure", "Another user has updated this LifePlan while you were editing.")
+                    render(view:'edit',model:[lifePlanInstance:lifePlanInstance])
+                    return
+                }
+            }
+            lifePlanInstance.properties = params
+            if(!lifePlanInstance.hasErrors() && lifePlanInstance.save()) {
+                flash.message = "LifePlan ${params.id} updated"
+                redirect(action:show,id:lifePlanInstance.id)
+            }
+            else {
+                render(view:'edit',model:[lifePlanInstance:lifePlanInstance])
+            }
+        }
+        else {
+            flash.message = "LifePlan not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def lifePlanInstance = new LifePlan()
+        lifePlanInstance.properties = params
+        return ['lifePlanInstance':lifePlanInstance]
+    }
+
+    def save = {
+        def lifePlanInstance = new LifePlan(params)
+        if(!lifePlanInstance.hasErrors() && lifePlanInstance.save()) {
+            flash.message = "LifePlan ${lifePlanInstance.id} created"
+            redirect(action:show,id:lifePlanInstance.id)
+        }
+        else {
+            render(view:'create',model:[lifePlanInstance:lifePlanInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/SubAssemblyController.groovy
===================================================================
--- trunk/grails-app/controllers/SubAssemblyController.groovy	(revision 118)
+++ trunk/grails-app/controllers/SubAssemblyController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class SubAssemblyController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ subAssemblyInstanceList: SubAssembly.list( params ), subAssemblyInstanceTotal: SubAssembly.count() ]
+    }
+
+    def show = {
+        def subAssemblyInstance = SubAssembly.get( params.id )
+
+        if(!subAssemblyInstance) {
+            flash.message = "SubAssembly not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ subAssemblyInstance : subAssemblyInstance ] }
+    }
+
+    def delete = {
+        def subAssemblyInstance = SubAssembly.get( params.id )
+        if(subAssemblyInstance) {
+            try {
+                subAssemblyInstance.delete()
+                flash.message = "SubAssembly ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "SubAssembly ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "SubAssembly not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def subAssemblyInstance = SubAssembly.get( params.id )
+
+        if(!subAssemblyInstance) {
+            flash.message = "SubAssembly not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ subAssemblyInstance : subAssemblyInstance ]
+        }
+    }
+
+    def update = {
+        def subAssemblyInstance = SubAssembly.get( params.id )
+        if(subAssemblyInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(subAssemblyInstance.version > version) {
+                    
+                    subAssemblyInstance.errors.rejectValue("version", "subAssembly.optimistic.locking.failure", "Another user has updated this SubAssembly while you were editing.")
+                    render(view:'edit',model:[subAssemblyInstance:subAssemblyInstance])
+                    return
+                }
+            }
+            subAssemblyInstance.properties = params
+            if(!subAssemblyInstance.hasErrors() && subAssemblyInstance.save()) {
+                flash.message = "SubAssembly ${params.id} updated"
+                redirect(action:show,id:subAssemblyInstance.id)
+            }
+            else {
+                render(view:'edit',model:[subAssemblyInstance:subAssemblyInstance])
+            }
+        }
+        else {
+            flash.message = "SubAssembly not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def subAssemblyInstance = new SubAssembly()
+        subAssemblyInstance.properties = params
+        return ['subAssemblyInstance':subAssemblyInstance]
+    }
+
+    def save = {
+        def subAssemblyInstance = new SubAssembly(params)
+        if(!subAssemblyInstance.hasErrors() && subAssemblyInstance.save()) {
+            flash.message = "SubAssembly ${subAssemblyInstance.id} created"
+            redirect(action:show,id:subAssemblyInstance.id)
+        }
+        else {
+            render(view:'create',model:[subAssemblyInstance:subAssemblyInstance])
+        }
+    }
+}
Index: trunk/grails-app/controllers/SystemSectionController.groovy
===================================================================
--- trunk/grails-app/controllers/SystemSectionController.groovy	(revision 118)
+++ trunk/grails-app/controllers/SystemSectionController.groovy	(revision 118)
@@ -0,0 +1,99 @@
+import org.codehaus.groovy.grails.plugins.springsecurity.Secured
+
+class SystemSectionController extends BaseAppAdminController {
+    
+    def index = { redirect(action:list,params:params) }
+
+    // the delete, save and update actions only accept POST requests
+    static allowedMethods = [delete:'POST', save:'POST', update:'POST']
+
+    def list = {
+        params.max = Math.min( params.max ? params.max.toInteger() : 10,  100)
+        [ systemSectionInstanceList: SystemSection.list( params ), systemSectionInstanceTotal: SystemSection.count() ]
+    }
+
+    def show = {
+        def systemSectionInstance = SystemSection.get( params.id )
+
+        if(!systemSectionInstance) {
+            flash.message = "SystemSection not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else { return [ systemSectionInstance : systemSectionInstance ] }
+    }
+
+    def delete = {
+        def systemSectionInstance = SystemSection.get( params.id )
+        if(systemSectionInstance) {
+            try {
+                systemSectionInstance.delete()
+                flash.message = "SystemSection ${params.id} deleted"
+                redirect(action:list)
+            }
+            catch(org.springframework.dao.DataIntegrityViolationException e) {
+                flash.message = "SystemSection ${params.id} could not be deleted"
+                redirect(action:show,id:params.id)
+            }
+        }
+        else {
+            flash.message = "SystemSection not found with id ${params.id}"
+            redirect(action:list)
+        }
+    }
+
+    def edit = {
+        def systemSectionInstance = SystemSection.get( params.id )
+
+        if(!systemSectionInstance) {
+            flash.message = "SystemSection not found with id ${params.id}"
+            redirect(action:list)
+        }
+        else {
+            return [ systemSectionInstance : systemSectionInstance ]
+        }
+    }
+
+    def update = {
+        def systemSectionInstance = SystemSection.get( params.id )
+        if(systemSectionInstance) {
+            if(params.version) {
+                def version = params.version.toLong()
+                if(systemSectionInstance.version > version) {
+                    
+                    systemSectionInstance.errors.rejectValue("version", "systemSection.optimistic.locking.failure", "Another user has updated this SystemSection while you were editing.")
+                    render(view:'edit',model:[systemSectionInstance:systemSectionInstance])
+                    return
+                }
+            }
+            systemSectionInstance.properties = params
+            if(!systemSectionInstance.hasErrors() && systemSectionInstance.save()) {
+                flash.message = "SystemSection ${params.id} updated"
+                redirect(action:show,id:systemSectionInstance.id)
+            }
+            else {
+                render(view:'edit',model:[systemSectionInstance:systemSectionInstance])
+            }
+        }
+        else {
+            flash.message = "SystemSection not found with id ${params.id}"
+            redirect(action:edit,id:params.id)
+        }
+    }
+
+    def create = {
+        def systemSectionInstance = new SystemSection()
+        systemSectionInstance.properties = params
+        return ['systemSectionInstance':systemSectionInstance]
+    }
+
+    def save = {
+        def systemSectionInstance = new SystemSection(params)
+        if(!systemSectionInstance.hasErrors() && systemSectionInstance.save()) {
+            flash.message = "SystemSection ${systemSectionInstance.id} created"
+            redirect(action:show,id:systemSectionInstance.id)
+        }
+        else {
+            render(view:'create',model:[systemSectionInstance:systemSectionInstance])
+        }
+    }
+}
