Changeset 279
- Timestamp:
- Mar 17, 2010, 3:18:54 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/grails-app/controllers/dbnp/studycapturing/WizardController.groovy
r278 r279 502 502 println "saved study "+flow.study+" (id: "+flow.study.id+")" 503 503 504 // commit transaction 505 println "commit" 506 transaction.commit() 507 success() 504 508 } catch (Exception e) { 505 509 // rollback 510 this.appendErrorMap(['exception': e.toString() + ', see log for stacktrace' ], flash.errors) 511 512 // debug line 513 println e.printStackTrace() 514 506 515 println "rollback" 507 516 transaction.rollback() 508 517 error() 509 518 } 510 511 // commit transaction512 println "commit"513 transaction.commit()514 success()515 519 } 516 520 on("error").to "error" -
trunk/grails-app/views/wizard/common/_error.gsp
r250 r279 36 36 37 37 // show error dialog 38 $(function() { 39 $("div#wizardError").dialog({ 40 modal: true, 41 width: 600, 42 buttons: { 43 Ok: function() { 44 $(this).dialog('close'); 45 } 38 $("div#wizardError").dialog({ 39 modal: true, 40 width: 600, 41 buttons: { 42 Ok: function() { 43 $(this).dialog('close'); 46 44 } 47 } );45 } 48 46 }); 49 47 </script> -
trunk/grails-app/views/wizard/common/_navigation.gsp
r247 r279 15 15 %> 16 16 <div class="navigation"> 17 <g:if test="${page>1 }"><wizard:ajaxButton name="previous" value="« prev" url="[controller:'wizard',action:'pages']" update="[success:'wizardPage',failure:'wizardError']" afterSuccess="onWizardPage()" class="prevnext" /></g:if>17 <g:if test="${page>1 && page<pages.size}"><wizard:ajaxButton name="previous" value="« prev" url="[controller:'wizard',action:'pages']" update="[success:'wizardPage',failure:'wizardError']" afterSuccess="onWizardPage()" class="prevnext" /></g:if> 18 18 <g:if test="${page>1 && page<pages.size}"> | </g:if> 19 19 <g:if test="${page<pages.size}"><wizard:ajaxButton name="next" value="next »" url="[controller:'wizard',action:'pages']" update="[success:'wizardPage',failure:'wizardError']" afterSuccess="onWizardPage()" class="prevnext" /></g:if> -
trunk/grails-app/views/wizard/pages/_done.gsp
r275 r279 22 22 </span> 23 23 24 <script type="text/javascript"> 25 // disable redirect warning 26 var warnOnRedirect = false; 27 </script> 28 24 29 </wizard:pageContent> -
trunk/web-app/js/wizard.js
r275 r279 13 13 * $Date$ 14 14 */ 15 var warnOnRedirect = true; 15 16 $(document).ready(function() { 16 17 // check if user is using Firefox 3.6 and warm the user … … 61 62 if (!element.attr('href').match(/^#/gi) && !element.attr('href').match(/\/([^\/]+)\/wizard\/pages/gi)) { 62 63 // bind a warning to the onclick event 63 element.bind('click',function() { return onDirectWarning(); }); 64 element.bind('click',function() { 65 if (warnOnRedirect) { 66 return onDirectWarning(); 67 } 68 }); 64 69 } 65 70 })
Note: See TracChangeset
for help on using the changeset viewer.