Changeset 139 for trunk/grails-app/controllers/AppCoreController.groovy
- Timestamp:
- Sep 28, 2009, 10:01:43 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/AppCoreController.groovy
r134 r139 5 5 def authenticateService 6 6 7 def index = { redirect(action: home,params:params) }7 def index = { redirect(action:start,params:params) } 8 8 9 9 // the delete, save and update actions only accept POST requests 10 10 //def allowedMethods = [delete:'POST', save:'POST', update:'POST'] 11 11 12 /** 13 * This is where we arrive after login. 14 * Attach the welcome flash message and redirect to where ever we want the user to start. 15 * e.g. redirect(controller:"taskDetailed", action:"search") 16 */ 12 17 def welcome = { 13 18 def personInstance = Person.get(authenticateService.userDomain().id) … … 16 21 def sess = getSession() 17 22 sess.setMaxInactiveInterval(personInstance.sessionTimeout) 18 redirect(action: home)23 redirect(action:start) 19 24 } 20 25 21 def home = { 22 } 23 24 def options = { 25 } 26 27 def acknowledgements = { 26 def start = { 28 27 } 29 28 … … 35 34 if (request.method == 'POST') { 36 35 def personInstance = Person.get(authenticateService.userDomain().id) 37 // personInstance.sessionTimeout = params.sessionTimeout.toInteger()38 36 personInstance.properties = params 39 37 if (!personInstance.hasErrors() && personInstance.save()) { … … 41 39 sess.setMaxInactiveInterval(personInstance.sessionTimeout) 42 40 flash.message = "Session timeout changed." 43 redirect(action: options)41 redirect(action:start) 44 42 } 45 43 else { … … 68 66 //userCache.removeUserFromCache(personInstance.loginName) 69 67 flash.message = "Password changed successfully." 70 redirect(action: options)68 redirect(action:start) 71 69 } 72 70 else {
Note: See TracChangeset
for help on using the changeset viewer.