Changeset 216 for trunk/grails-app/controllers
- Timestamp:
- Dec 4, 2009, 2:05:27 PM (15 years ago)
- Location:
- trunk/grails-app/controllers
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/AppCoreController.groovy
r185 r216 17 17 */ 18 18 def welcome = { 19 def personInstance = personService.currentUser ()19 def personInstance = personService.currentUser 20 20 flash.message = "Welcome, ${personInstance.firstName} ${personInstance.lastName}." 21 21 … … 30 30 def changeSessionTimeout = { 31 31 if (request.method == 'GET') { 32 def personInstance = personService.currentUser ()32 def personInstance = personService.currentUser 33 33 return [ personInstance : personInstance ] 34 34 } 35 35 if (request.method == 'POST') { 36 def personInstance = personService.currentUser ()36 def personInstance = personService.currentUser 37 37 personInstance.properties = params 38 38 if (!personInstance.hasErrors() && personInstance.save(flush: true)) { … … 53 53 54 54 if (request.method == 'GET') { 55 def personInstance = personService.currentUser ()55 def personInstance = personService.currentUser 56 56 return [ personInstance : personInstance ] 57 57 } 58 58 59 59 if (request.method == 'POST') { 60 def personInstance = personService.currentUser ()60 def personInstance = personService.currentUser 61 61 62 62 if(params.confirmPass == params.pass) { -
trunk/grails-app/controllers/EntryDetailedController.groovy
r191 r216 29 29 def entryInstance = Entry.get( params.id ) 30 30 if(entryInstance) { 31 if(entryInstance.enteredBy.loginName == personService.currentUser ().loginName) {31 if(entryInstance.enteredBy.loginName == personService.currentUser.loginName) { 32 32 def taskID = entryInstance.task.id 33 33 entryInstance.delete(flush:true) … … 55 55 else { 56 56 57 if(entryInstance.enteredBy.loginName == personService.currentUser ().loginName) {57 if(entryInstance.enteredBy.loginName == personService.currentUser.loginName) { 58 58 return [ entryInstance : entryInstance ] 59 59 } … … 70 70 if(entryInstance) { 71 71 // The update method only accepts post requests, so this is just in case. 72 if(entryInstance.enteredBy.loginName == personService.currentUser ().loginName) {72 if(entryInstance.enteredBy.loginName == personService.currentUser.loginName) { 73 73 entryInstance.properties = params 74 74 if(!entryInstance.hasErrors() && entryInstance.save(flush: true)) { -
trunk/grails-app/controllers/TaskDetailedController.groovy
r214 r216 28 28 if(!FilterUtils.isFilterApplied(params)) { 29 29 def taskInstanceList = [] 30 def personInstance = personService.currentUser ()30 def personInstance = personService.currentUser 31 31 32 32 if(params.quickSearch == "searchMyTodays") { … … 67 67 if(!FilterUtils.isFilterApplied(params)) { 68 68 def taskInstanceList = [] 69 def personInstance = personService.currentUser ()69 def personInstance = personService.currentUser 70 70 71 71 if(params.quickSearch == "searchMyTodays") { … … 112 112 if(!FilterUtils.isFilterApplied(params)) { 113 113 def taskInstanceList = [] 114 def personInstance = personService.currentUser ()114 def personInstance = personService.currentUser 115 115 116 116 if(params.quickSearch == "budgetUnplanned") { … … 416 416 417 417 // Default leadPerson to current user, unless supplied in params. 418 taskInstance.leadPerson = personService.currentUser ()418 taskInstance.leadPerson = personService.currentUser 419 419 taskInstance.properties = params 420 420 return ['taskInstance': taskInstance]
Note: See TracChangeset
for help on using the changeset viewer.