]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-2706 Add loading icon as the linking action can be long
authorFabrice Bellingard <bellingard@gmail.com>
Mon, 14 May 2012 07:22:55 +0000 (09:22 +0200)
committerFabrice Bellingard <bellingard@gmail.com>
Mon, 14 May 2012 13:11:02 +0000 (15:11 +0200)
sonar-server/src/main/webapp/WEB-INF/app/views/project_reviews/_review_command_form.html.erb
sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_violation_comment_form.html.erb

index cc4ff3bb746f7d004579b1894041cef54f2c6323..285bfcc4611c526dffc962daf47b914dc0a75c49 100644 (file)
@@ -7,7 +7,10 @@
                        @review_command.getName(),
                        :url => {:action => 'run_review_command'},
                        :html => {:id => "submit_btn"},
+                       :loading => "$('loading').show();",
                        :update => 'review' -%>
   &nbsp;
   <%= link_to_remote message('cancel'), :url => {:action => 'show', :id => params[:id]}, :update => 'review' -%>
+    &nbsp;
+    <span id="loading" style="display: none;"><%= image_tag 'loading.gif' -%></span>
 </form>
index fcf463c4d9ebc1c5cd48b3193af5c82e9be3b6a1..3180334ab9684ab2479755291689834e13baee91 100644 (file)
                          button_label,
                          :url => {:action => 'violation_save_comment'},
                          :html => {:id => "submit_btn"+params[:id]}.merge(@review_command ? {} : {:disabled => "true"}),
+                         :loading => "$('loading-#{params[:id]}').show();",
                          :update => 'vId'+params[:id] -%>
     &nbsp;
     <%= link_to_function message('cancel'), "cancelViolationAction(#{params[:id]})" -%>
+    &nbsp;
+    <span id="loading-<%= params[:id] -%>" style="display: none;"><%= image_tag 'loading.gif' -%></span>
   </div>
 </form>