From 8a9e2b47adf28f03080602a32279f4b2b3e11c2b Mon Sep 17 00:00:00 2001 From: z9hang Date: Thu, 31 Jul 2014 10:21:11 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E7=94=A8=E5=AD=98=E5=82=A8=E8=BF=87?= =?UTF-8?q?=E7=A8=8B=E5=88=B7=E6=96=B0=E9=A1=B9=E7=9B=AE=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=E6=AC=A1=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/projects_controller.rb | 3 +++ app/views/projects/_project.html.erb | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 15a26fbae..9b2481c1b 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -103,6 +103,8 @@ class ProjectsController < ApplicationController end def index + #调用存储过程更新提交次数 + ActiveRecord::Base.connection.execute("CALL sp_project_status_cursor();") #Modified by nie @project_type = params[:project_type].to_i per_page_option = 10 @@ -150,6 +152,7 @@ class ProjectsController < ApplicationController end @projects = @projects.offset(@project_pages.offset).limit(@project_pages.per_page) + respond_to do |format| format.html { render :layout => 'base' diff --git a/app/views/projects/_project.html.erb b/app/views/projects/_project.html.erb index 3c858cce6..41ad2a62c 100644 --- a/app/views/projects/_project.html.erb +++ b/app/views/projects/_project.html.erb @@ -45,7 +45,7 @@ - <% find_project_repository @project %> + <% #find_project_repository @project %> <%= content_tag('span', "#{@project.repository.nil? || @project.project_status.nil? ? '0' : @project.project_status.changesets_count }", :class => "info") %>