diff --git a/app/assets/javascripts/group_live_entry.js b/app/assets/javascripts/group_live_entry.js index 7750e22ac..50a0e26ba 100644 --- a/app/assets/javascripts/group_live_entry.js +++ b/app/assets/javascripts/group_live_entry.js @@ -130,7 +130,7 @@ } else { $('#js-group-new-times-alert').fadeTo(500, 0, function() {$('#js-group-new-times-alert').hide()}); } - $('#js-group-pull-times-count').text(text); + $('#js-pull-times-count').text(text); } }, @@ -999,13 +999,26 @@ liveEntry.timeRowsTable.busy = false; } }); - $('#js-group-import-live-times').on('click', function (event) { + + $(document).on('keydown', function (event) { + if(event.keyCode === 16) { + $('#js-import-live-times').hide(); + $('#js-force-import-live-times').show() + } + }); + $(document).on('keyup', function (event) { + if(event.keyCode === 16) { + $('#js-force-import-live-times').hide(); + $('#js-import-live-times').show() + } + }); + $('#js-import-live-times, #js-force-import-live-times').on('click', function (event) { event.preventDefault(); if (liveEntry.importAsyncBusy) { return; } liveEntry.importAsyncBusy = true; - var forceParam = (event.shiftKey) ? '?forcePull=true' : ''; + var forceParam = (this.id === 'js-import-live-times') ? '?forcePull=true' : ''; $.ajax('/api/v1/event_groups/' + liveEntry.currentEventGroupId + '/pull_live_time_rows' + forceParam, { error: function(obj, error) { liveEntry.importAsyncBusy = false; diff --git a/app/views/live/event_groups/live_entry.html.erb b/app/views/live/event_groups/live_entry.html.erb index ec423d416..cf7995288 100644 --- a/app/views/live/event_groups/live_entry.html.erb +++ b/app/views/live/event_groups/live_entry.html.erb @@ -4,7 +4,7 @@

@@ -205,13 +205,15 @@
-
-
- -
+
+ +