This commit is contained in:
Your Name 2016-06-30 10:17:53 +08:00
parent daf14178cd
commit 5c83414828
3 changed files with 11 additions and 1 deletions

View File

@ -85,6 +85,14 @@ class QualityAnalysisController < ApplicationController
end
end
def edit
@quality_analysis = QualityAnalysis.where(:id => params[:id])
end
def update
@quality_analysis = QualityAnalysis.where(:id => params[:id])
end
# resource_id: login + @repository.id
def index
begin

View File

@ -7,6 +7,7 @@
<li class="analysis-result-loc fl fontBlue2" >分支</li>
<li class="analysis-result-debt fl fontBlue2" >语言</li>
<li class="analysis-result-time fl fontBlue2" >路径</li>
<li class="analysis-result-time fl fontBlue2" >bianji</li>
<div class="cl"></div>
</ul>
<% if @quality_analyses.count >0 %>
@ -17,6 +18,7 @@
<li class="analysis-result-loc fl fontBlue2" title="分支名"><%= qa.branch %></li>
<li class="analysis-result-debt fl fontBlue2" title="语言"><%= qa.language %></li>
<li class="analysis-result-time fl fontBlue2" title="时间"><%= qa.path %></li>
<li class="analysis-result-time fl fontBlue2" title="时间"><%=link_to "bianji", edit_project__quality_analysis_path(@quality_analysis) %></li>
<div class="cl"></div>
</ul>
<% end %>

View File

@ -786,7 +786,7 @@ RedmineApp::Application.routes.draw do
end
end
resources :quality_analysis, :only => [:index, :new, :create] do
resources :quality_analysis, :only => [:index, :create, :edit, :update] do
collection do
end
member do