- Timestamp:
- Jan 23, 2010, 11:33:04 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/AssetExtendedAttributeDetailedController.groovy
r292 r293 2 2 3 3 class AssetExtendedAttributeDetailedController extends BaseController { 4 5 def index = { redirect( action:list,params:params) }4 5 def index = { redirect(controller: "assetDetailed", action: "search", params:params) } 6 6 7 7 // the delete, save and update actions only accept POST requests 8 8 static allowedMethods = [delete:'POST', save:'POST', update:'POST'] 9 10 def list = {11 params.max = Math.min( params.max ? params.max.toInteger() : 10, 100)12 [ assetExtendedAttributeInstanceList: AssetExtendedAttribute.list( params ), assetExtendedAttributeInstanceTotal: AssetExtendedAttribute.count() ]13 }14 9 15 10 def show = { … … 18 13 if(!assetExtendedAttributeInstance) { 19 14 flash.message = "AssetExtendedAttribute not found with id ${params.id}" 20 redirect( action:list)15 redirect(controller: "assetDetailed", action: "search") 21 16 } 22 17 else { return [ assetExtendedAttributeInstance : assetExtendedAttributeInstance ] } … … 29 24 assetExtendedAttributeInstance.delete(flush:true) 30 25 flash.message = "AssetExtendedAttribute ${params.id} deleted" 31 redirect( action:list)26 redirect(controller: "assetDetailed", action: "search") 32 27 } 33 28 catch(org.springframework.dao.DataIntegrityViolationException e) { … … 38 33 else { 39 34 flash.message = "AssetExtendedAttribute not found with id ${params.id}" 40 redirect( action:list)35 redirect(controller: "assetDetailed", action: "search") 41 36 } 42 37 } … … 47 42 if(!assetExtendedAttributeInstance) { 48 43 flash.message = "AssetExtendedAttribute not found with id ${params.id}" 49 redirect( action:list)44 redirect(controller: "assetDetailed", action: "search") 50 45 } 51 46 else { … … 77 72 else { 78 73 flash.message = "AssetExtendedAttribute not found with id ${params.id}" 79 redirect( action:list)74 redirect(controller: "assetDetailed", action: "search") 80 75 } 81 76 }
Note: See TracChangeset
for help on using the changeset viewer.