X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/78a1683680177da480dc3ffaea2d4f2b79ab793d..4baccff09d5f8c48cc3c431365f1e029a8c40bb1:/apps/workbench/app/assets/javascripts/application.js diff --git a/apps/workbench/app/assets/javascripts/application.js b/apps/workbench/app/assets/javascripts/application.js index dc7177060e..e7884b9516 100644 --- a/apps/workbench/app/assets/javascripts/application.js +++ b/apps/workbench/app/assets/javascripts/application.js @@ -41,6 +41,7 @@ jQuery(function($){ } targets.fadeToggle(200); }); + $(document). on('ajax:send', function(e, xhr) { $('.loading').fadeTo('fast', 1); @@ -83,7 +84,7 @@ jQuery(function($){ parent(). find('>span'). append(new_tag_span). - append(' '); + append('  '); $.ajax($(this).attr('data-remote-href'), {dataType: 'json', type: $(this).attr('data-remote-method'), @@ -105,10 +106,11 @@ jQuery(function($){ }); HeaderRowFixer = function(selector) { - var tables = $(selector); this.duplicateTheadTr = function() { - tables.each(function() { + $(selector).each(function() { var the_table = this; + if ($('>tbody>tr:first>th', the_table).length > 0) + return; $('>tbody', the_table). prepend($('>thead>tr', the_table). clone(). @@ -116,9 +118,9 @@ jQuery(function($){ }); } this.fixThead = function() { - tables.each(function() { + $(selector).each(function() { var widths = []; - $('> tbody > tr:eq(0) > td', this).each( function(i,v){ + $('> tbody > tr:eq(1) > td', this).each( function(i,v){ widths.push($(v).width()); }); for(i=0;i