diff options
author | Valery Sizov <vsv2711@gmail.com> | 2015-05-19 16:56:54 +0300 |
---|---|---|
committer | Valery Sizov <vsv2711@gmail.com> | 2015-05-19 17:42:53 +0300 |
commit | 38d332e709ca549b0eadadaaf66151077d5598e5 (patch) | |
tree | 09ab6caa10ee08d00aa2b824926188eb61fe182c | |
parent | fec88acd3fcc386eb934d9f59b227c784ddda456 (diff) | |
download | gitlab-ci-38d332e709ca549b0eadadaaf66151077d5598e5.tar.gz |
fix Sync now btn
-rw-r--r-- | app/views/projects/gitlab.html.haml | 2 | ||||
-rw-r--r-- | app/views/projects/index.html.haml | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/app/views/projects/gitlab.html.haml b/app/views/projects/gitlab.html.haml index 2ce795f..aef0237 100644 --- a/app/views/projects/gitlab.html.haml +++ b/app/views/projects/gitlab.html.haml @@ -5,7 +5,7 @@ - if params[:search].present? by keyword: "#{params[:search]}", #{time_ago_in_words(current_user.sync_at)} ago. - = link_to gitlab_projects_path(reset_cache: true, search: params[:search]), remote: true, class: 'sync-now btn btn-small btn-default' do + = link_to gitlab_projects_path(reset_cache: true, search: params[:search]), class: 'sync-now btn btn-small btn-default reset-cache' do %i.icon-refresh Sync now %br diff --git a/app/views/projects/index.html.haml b/app/views/projects/index.html.haml index 7be5439..b6d7629 100644 --- a/app/views/projects/index.html.haml +++ b/app/views/projects/index.html.haml @@ -12,6 +12,9 @@ :coffeescript $.get '#{gitlab_projects_path}', (data) -> $(".projects").html data.html + $('.projects').on 'click', '.reset-cache', -> + $.get '#{gitlab_projects_path}', { reset_cache: true }, (data) -> + $(".projects").html data.html Pager.init "#{gitlab_projects_path}", #{ProjectsController::PROJECTS_BATCH}, false - else |