diff --git a/plugins/mezuro/views/mezuro_plugin_myprofile/edit_compound_metric_configuration.html.erb b/plugins/mezuro/views/mezuro_plugin_myprofile/edit_compound_metric_configuration.html.erb index 49e514b..a7dcd6c 100644 --- a/plugins/mezuro/views/mezuro_plugin_myprofile/edit_compound_metric_configuration.html.erb +++ b/plugins/mezuro/views/mezuro_plugin_myprofile/edit_compound_metric_configuration.html.erb @@ -1,25 +1,28 @@
- <%= f.label :metric_name, "Metric Name:" %> - <%= @metric.name %> - <%= hidden_field_tag "metric[name]", @metric.name %> -
-- <%= f.label :description, "Description:" %> - <%= text_field_tag "metric[description]", @metric.description %> -
-- <%= f.label :scope, "Scope:" %> - <%= select_tag "metric[scope]", options_for_select([["Teste", "NIL"], ["Class", "CLASS"]], :selected => @metric.scope) %> -
+ <%= "Metric Name:" + @metric.name %> + + <% f.fields_for :metric do |m| %> + <%= m.hidden_field :name, :value => @metric.name %> ++ <%= m.label :description, "Description:" %> + <%= m.text_field "description" %> +
++ <%= m.label :scope, "Scope:" %> + <%= m.select :scope, [["Teste", "NIL"], ["Class", "CLASS"]] %> +
++ <%= m.label :script, "Script:" %> + <%= m.text_area "script" %> +
+ <% end %><%= f.label :code, "Code:" %> - <%= text_field_tag "metric[code]", @metric_configuration.code %> + <%= f.text_field "code" %>
<%= f.label :aggregation_form, "Aggregation Form:" %> @@ -30,12 +33,6 @@ <%= f.label :weight, "Weight:" %> <%= f.text_field :weight %>
- -- <%= f.label :script, "Script:" %> - <%= text_area_tag "metric[script]", @metric.script %> -
-<%= f.submit "Save" %>
-- libgit2 0.21.2