Changeset 1152
- Timestamp:
- Nov 17, 2010, 10:45:55 AM (10 years ago)
- Location:
- trunk/grails-app
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/dbnp/authentication/RegisterController.groovy
r985 r1152 46 46 String username = params.username 47 47 if (!username) { 48 flash. error = message(code: 'spring.security.ui.forgotPassword.username.missing')48 flash.userError = message(code: 'spring.security.ui.forgotPassword.username.missing') 49 49 return 50 50 } … … 52 52 def user = SecUser.findByUsername(username) 53 53 if (!user) { 54 flash. error = message(code: 'spring.security.ui.forgotPassword.user.notFound')54 flash.userError = message(code: 'spring.security.ui.forgotPassword.user.notFound') 55 55 return 56 56 } … … 79 79 def registrationCode = token ? RegistrationCode.findByToken(token) : null 80 80 if (!registrationCode) { 81 flash. error = message(code: 'spring.security.ui.resetPassword.badCode')81 flash.userError = message(code: 'spring.security.ui.resetPassword.badCode') 82 82 redirect uri: SpringSecurityUtils.securityConfig.successHandler.defaultTargetUrl 83 83 return -
trunk/grails-app/controllers/dbnp/authentication/UserController.groovy
r996 r1152 102 102 } 103 103 catch (DataIntegrityViolationException e) { 104 flash. error = "${message(code: 'default.not.deleted.message', args: [message(code: 'user.label', default: 'User'), params.id])}"104 flash.userError = "${message(code: 'default.not.deleted.message', args: [message(code: 'user.label', default: 'User'), params.id])}" 105 105 redirect action: edit, id: params.id 106 106 } -
trunk/grails-app/views/register/forgotPassword.gsp
r976 r1152 10 10 <g:form action='forgotPassword' name="forgotPasswordForm" autocomplete='off'> 11 11 12 13 12 14 <g:if test='${emailSent}'> 13 15 <br/> 14 16 <g:message code='spring.security.ui.forgotPassword.sent'/> 15 17 </g:if> 16 17 18 <g:else> 18 19 … … 20 21 <h4><g:message code='spring.security.ui.forgotPassword.description'/></h4> 21 22 22 <table> 23 <tr> 24 <td><label for="username"><g:message code='spring.security.ui.forgotPassword.username'/></label></td> 25 <td><g:textField name="username" size="25" /></td> 26 </tr> 27 </table> 23 <g:if test='${flash.userError}'> 24 ${flash.userError} 25 <br/> 26 </g:if> 27 <table> 28 <tr> 29 <td><label for="username"><g:message code='spring.security.ui.forgotPassword.username'/></label></td> 30 <td><g:textField name="username" size="25" /></td> 31 </tr> 32 </table> 28 33 29 34 <input type="submit" value="Reset my password"> -
trunk/grails-app/views/user/edit.gsp
r996 r1152 17 17 <body> 18 18 <script src="${resource(dir: 'js', file: 'jquery-callback-1.2.js')}" type="text/javascript"></script> 19 <h3><g:message code="default.edit.label" args="[entityName]"/></h3> 19 20 <g:if test="${flash.userError}"> 21 <div id="error" class="error" title="errors"> 22 <p> 23 ${flash.userError} 24 </p> 25 </div> 26 <h3><g:message code="default.edit.label" args="[entityName]"/></h3> 20 27 21 28 <g:form action="update" name='userEditForm' class="button-style">
Note: See TracChangeset
for help on using the changeset viewer.