Commit 670bf6148f207b5ec49c42ede1d6cc1f2ddd5748
Committed by
Rafael Manzo
1 parent
82f20565
Exists in
colab
and in
4 other branches
Created controller to get the ajax requisitions from metrics.
Showing
3 changed files
with
16 additions
and
1 deletions
Show diff stats
app/views/repositories/_metric_result.html.erb
| ... | ... | @@ -2,7 +2,10 @@ |
| 2 | 2 | <% unless metric_configuration_snapshot.range_snapshot.nil? %> |
| 3 | 3 | <% range_snapshot = find_range_snapshot(metric_result) %> |
| 4 | 4 | <tr> |
| 5 | - <td><%= link_to metric_configuration_snapshot.metric.name, "#metric_#{module_result.id}", onclick: "chart_of_the_historic_of_metric(#{metric_result.id},\'#{metric_configuration_snapshot.metric.name}\', \'#{module_result.module.name}\', '12/09/2012,21/10/2013,30/05/2013','12.7,13,20')", id: "metirc_#{module_result.id}" %></td> | |
| 5 | + <td><%= link_to metric_configuration_snapshot.metric.name, "#metric_#{module_result.id}", | |
| 6 | + onclick: "chart_of_the_historic_of_metric(#{metric_result.id},\'#{metric_configuration_snapshot.metric.name}\', \'#{module_result.module.name}\', '12/09/2012,21/10/2013,30/05/2013','12.7,13,20')", | |
| 7 | + id: "metirc_#{module_result.id}", | |
| 8 | + remote: true %></td> | |
| 6 | 9 | <td><%= format_grade(metric_result.value) %></td> |
| 7 | 10 | <td><%= metric_configuration_snapshot.weight %></td> |
| 8 | 11 | <td><span style="color: #<%= range_snapshot.color %>"><%= range_snapshot.label %></span></td> | ... | ... |
config/routes.rb
| ... | ... | @@ -10,7 +10,11 @@ Mezuro::Application.routes.draw do |
| 10 | 10 | put '/repositories/:id' => 'repositories#update', as: :repository_update |
| 11 | 11 | end |
| 12 | 12 | |
| 13 | + #resources :modules | |
| 14 | + get '/modules/metric_history' => 'modules#metric_history' | |
| 15 | + | |
| 13 | 16 | root "home#index" |
| 17 | + | |
| 14 | 18 | # The priority is based upon order of creation: first created -> highest priority. |
| 15 | 19 | # See how all your routes lay out with "rake routes". |
| 16 | 20 | ... | ... |