[hg] galaxy 3382: trackster: clicking enter should continue
details: http://www.bx.psu.edu/hg/galaxy/rev/c8c472e6f341 changeset: 3382:c8c472e6f341 user: Kanwei Li <kanwei@gmail.com> date: Fri Feb 12 15:09:00 2010 -0500 description: trackster: clicking enter should continue diffstat: templates/tracks/browser.mako | 11 ++++++----- templates/tracks/new_browser.mako | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diffs (36 lines): diff -r 205d55699a10 -r c8c472e6f341 templates/tracks/browser.mako --- a/templates/tracks/browser.mako Fri Feb 12 14:01:45 2010 -0500 +++ b/templates/tracks/browser.mako Fri Feb 12 15:09:00 2010 -0500 @@ -96,17 +96,18 @@ %endfor init(); %else: + continue_fn = function() { + view = new View( undefined, $("#new-title").val(), undefined, $("#new-dbkey").val() ); + init(); + hide_modal(); + }; $.ajax({ url: "${h.url_for( action='new_browser' )}", data: {}, error: function() { alert( "Couldn't create new browser" ) }, success: function(form_html) { show_modal("New Track Browser", form_html, { - "Continue": function() { - view = new View( undefined, $("#new-title").val(), undefined, $("#new-dbkey").val() ); - init(); - hide_modal(); - } + "Continue": continue_fn }); } }); diff -r 205d55699a10 -r c8c472e6f341 templates/tracks/new_browser.mako --- a/templates/tracks/new_browser.mako Fri Feb 12 14:01:45 2010 -0500 +++ b/templates/tracks/new_browser.mako Fri Feb 12 15:09:00 2010 -0500 @@ -1,4 +1,4 @@ -<form id="form" method="POST"> +<form id="new-browser-form" method="post" onsubmit="continue_fn(); return false;"> <div class="form-row"> <label for="title">Browser name:</label> <div class="form-row-input">
participants (1)
-
Greg Von Kuster