Adapt structure according to LSG

pull/6827/head
Henriette Dinger 9 years ago
parent 580acc7260
commit cd547d1ca8
  1. 13
      lib/widget/cost_types.rb

@ -32,10 +32,15 @@ class Widget::CostTypes < Widget::Base
def contents
content_tag :div do
available_cost_type_tabs(@subject).sort_by { |id, _| id }.map do |id, label|
type_selection = radio_button_tag('unit', id, id == @selected_type_id)
type_selection += label_tag "unit_#{id}", h(label)
type_selection
end.join('<br />').html_safe
content_tag :div, class: "form--field -trailing-label" do
types = label_tag "unit_#{id}", h(label), class: "form--label"
types += content_tag :span, class: "form--field-container" do
content_tag :span, class: "form--radio-button-container" do
radio_button_tag('unit', id, id == @selected_type_id, class: "form--radio-button")
end
end
end
end.join('').html_safe
end
end
end

Loading…
Cancel
Save