diff options
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/importer_status.js.coffee | 20 | ||||
-rw-r--r-- | app/views/import/base/create.js.haml | 2 | ||||
-rw-r--r-- | app/views/import/bitbucket/status.html.haml | 6 | ||||
-rw-r--r-- | app/views/import/fogbugz/status.html.haml | 4 | ||||
-rw-r--r-- | app/views/import/github/status.html.haml | 4 | ||||
-rw-r--r-- | app/views/import/gitlab/status.html.haml | 4 | ||||
-rw-r--r-- | app/views/import/gitorious/status.html.haml | 4 | ||||
-rw-r--r-- | app/views/import/google_code/status.html.haml | 6 |
8 files changed, 25 insertions, 25 deletions
diff --git a/app/assets/javascripts/importer_status.js.coffee b/app/assets/javascripts/importer_status.js.coffee index c51c4a1a182..95f9f86c0ad 100644 --- a/app/assets/javascripts/importer_status.js.coffee +++ b/app/assets/javascripts/importer_status.js.coffee @@ -4,16 +4,16 @@ class @ImporterStatus this.setAutoUpdate() initStatusPage: -> - $(".js-add-to-import") + $('.js-add-to-import') .off 'click' .on 'click', (event) => new_namespace = null $btn = $(event.currentTarget) - $tr = $btn.closest("tr") - id = $tr.attr("id").replace("repo_", "") - if $tr.find(".import-target input").length > 0 - new_namespace = $tr.find(".import-target input").prop("value") - $tr.find(".import-target").empty().append(new_namespace + "/" + $tr.find(".import-target").data("project_name")) + $tr = $btn.closest('tr') + id = $tr.attr('id').replace('repo_', '') + if $tr.find('.import-target input').length > 0 + new_namespace = $tr.find('.import-target input').prop('value') + $tr.find('.import-target').empty().append("#{new_namespace} / #{$tr.find('.import-target').data('project_name')}") $btn .disable() @@ -21,15 +21,15 @@ class @ImporterStatus $.post @import_url, {repo_id: id, new_namespace: new_namespace}, dataType: 'script' - $(".js-import-all") + $('.js-import-all') .off 'click' - .on 'click', (event) => - $btn = $(event.currentTarget) + .on 'click', (e) => + $btn = $(e.currentTarget) $btn .disable() .addClass 'is-loading' - $(".js-add-to-import").each -> + $('.js-add-to-import').each -> $(this).click() setAutoUpdate: -> diff --git a/app/views/import/base/create.js.haml b/app/views/import/base/create.js.haml index ec7a2b86566..dfebf7768d9 100644 --- a/app/views/import/base/create.js.haml +++ b/app/views/import/base/create.js.haml @@ -26,4 +26,4 @@ - else :plain job = $("tr#repo_#{@repo_id}") - job.find(".import-actions").html("<i class='fa fa-exclamation-circle'></i> Error saving project: #{escape_javascript(@project.errors.full_messages.join(','))}</i>") + job.find(".import-actions").html("<i class='fa fa-exclamation-circle'></i> Error saving project: #{escape_javascript(@project.errors.full_messages.join(','))}") diff --git a/app/views/import/bitbucket/status.html.haml b/app/views/import/bitbucket/status.html.haml index e24c01f3e0f..6e993e58f0d 100644 --- a/app/views/import/bitbucket/status.html.haml +++ b/app/views/import/bitbucket/status.html.haml @@ -12,11 +12,11 @@ - if @incompatible_repos.any? = button_tag class: "btn btn-import btn-success js-import-all" do Import all compatible projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") - else = button_tag class: "btn btn-success js-import-all" do Import all projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") .table-responsive %table.table.import-jobs @@ -55,7 +55,7 @@ %td.import-actions.job-status = button_tag class: "btn btn-import js-add-to-import" do Import - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") - @incompatible_repos.each do |repo| %tr{id: "repo_#{repo["owner"]}___#{repo["slug"]}"} %td diff --git a/app/views/import/fogbugz/status.html.haml b/app/views/import/fogbugz/status.html.haml index d842d1cbd94..d3d3c595c17 100644 --- a/app/views/import/fogbugz/status.html.haml +++ b/app/views/import/fogbugz/status.html.haml @@ -15,7 +15,7 @@ %p = button_tag class: 'btn btn-import btn-success js-import-all' do Import all projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") .table-responsive %table.table.import-jobs @@ -54,7 +54,7 @@ %td.import-actions.job-status = button_tag class: "btn btn-import js-add-to-import" do Import - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") :javascript new ImporterStatus("#{jobs_import_fogbugz_path}", "#{import_fogbugz_path}"); diff --git a/app/views/import/github/status.html.haml b/app/views/import/github/status.html.haml index d6fa0d8023b..9639da4cb58 100644 --- a/app/views/import/github/status.html.haml +++ b/app/views/import/github/status.html.haml @@ -10,7 +10,7 @@ %p = button_tag class: "btn btn-import btn-success js-import-all" do Import all projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") .table-responsive %table.table.import-jobs @@ -49,7 +49,7 @@ %td.import-actions.job-status = button_tag class: "btn btn-import js-add-to-import" do Import - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") :javascript new ImporterStatus("#{jobs_import_github_path}", "#{import_github_path}"); diff --git a/app/views/import/gitlab/status.html.haml b/app/views/import/gitlab/status.html.haml index 8f79f385610..e3a356b5379 100644 --- a/app/views/import/gitlab/status.html.haml +++ b/app/views/import/gitlab/status.html.haml @@ -10,7 +10,7 @@ %p = button_tag class: "btn btn-import btn-success js-import-all" do Import all projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") .table-responsive %table.table.import-jobs @@ -49,7 +49,7 @@ %td.import-actions.job-status = button_tag class: "btn js-add-to-import" do Import - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") :javascript new ImporterStatus("#{jobs_import_gitlab_path}", "#{import_gitlab_path}"); diff --git a/app/views/import/gitorious/status.html.haml b/app/views/import/gitorious/status.html.haml index f0256e0f934..267eee4f262 100644 --- a/app/views/import/gitorious/status.html.haml +++ b/app/views/import/gitorious/status.html.haml @@ -10,7 +10,7 @@ %p = button_tag class: "btn btn-import btn-success js-import-all" do Import all projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") .table-responsive %table.table.import-jobs @@ -49,7 +49,7 @@ %td.import-actions.job-status = button_tag class: "btn btn-import js-add-to-import" do Import - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") :javascript new ImporterStatus("#{jobs_import_gitorious_path}", "#{import_gitorious_path}"); diff --git a/app/views/import/google_code/status.html.haml b/app/views/import/google_code/status.html.haml index c4ac1b4f9b7..5ada6b174eb 100644 --- a/app/views/import/google_code/status.html.haml +++ b/app/views/import/google_code/status.html.haml @@ -16,11 +16,11 @@ - if @incompatible_repos.any? = button_tag class: "btn btn-import btn-success js-import-all" do Import all compatible projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") - else = button_tag class: "btn btn-import btn-success js-import-all" do Import all projects - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") .table-responsive %table.table.import-jobs @@ -59,7 +59,7 @@ %td.import-actions.job-status = button_tag class: "btn btn-import js-add-to-import" do Import - = icon('spinner spin', class: 'loading-icon') + = icon("spinner spin", class: "loading-icon") - @incompatible_repos.each do |repo| %tr{id: "repo_#{repo.id}"} %td |