fix markup for static label in work package view

Signed-off-by: Florian Kraft <f.kraft@finn.de>
pull/2612/head
Florian Kraft 10 years ago
parent d9c94731ef
commit 5f5376d944
No known key found for this signature in database
GPG Key ID: 786CD08D94605A9E
  1. 10
      app/helpers/work_packages_helper.rb

@ -520,7 +520,9 @@ module WorkPackagesHelper
required: true) required: true)
end end
elsif work_package.status elsif work_package.status
form.label(:status) + work_package.status.name work_package_form_field do
form.label(:status, class: "form--label") + wrap_element_in_container(work_package.status.name)
end
else else
form.label(:status) + empty_element_tag form.label(:status) + empty_element_tag
end end
@ -757,4 +759,10 @@ module WorkPackagesHelper
[responsible, assignee].compact.join('<br>').html_safe [responsible, assignee].compact.join('<br>').html_safe
end end
def wrap_element_in_container(name)
content_tag :span, class: "form--field-container" do
content_tag :span, name, class: "form--text-field-container"
end
end
end end

Loading…
Cancel
Save