Sha256: fb3c37f42e62a46d5135ed9700d42b21f25793168d704cb40cdc6f77b391cae3
Contents?: true
Size: 855 Bytes
Versions: 19
Compression:
Stored size: 855 Bytes
Contents
$ -> sourceId = $('#source_id').attr('value') updateFunc = -> $.ajax "/lit/sources/" + sourceId + "/sync_complete", type: 'GET' format: 'json' success: (xml, textStatus, xhr) -> if xhr.responseJSON.sync_complete $('.loading').addClass('loaded').removeClass('loading') clearInterval(interval) location.reload() statusCode: 404: -> $('.loading').text('Could not update synchronization status, please try refreshing page') 401: -> $('.loading').text('You are not authorized. Please check if you are properly logged in') 500: -> $('.loading').text('Something went wrong, please try synchronizing again') error: -> clearInterval(interval) if $('.loading').length > 0 interval = window.setInterval(updateFunc, 500)
Version data entries
19 entries across 19 versions & 2 rubygems