Sha256: 67d0af0db8278bc5cdc14b7d52d38d3b6db08aea5d0b28f49d2923cef783f098
Contents?: true
Size: 1.05 KB
Versions: 5
Compression:
Stored size: 1.05 KB
Contents
<% ## # Template per il rendering campo # - form -> FormBuilder # - form_field -> Array[String] %> <%# locals: (form:, form_field:) -%> <% button_group_classes = ["mb-1"] content = form_print_field(form, form_field) unless content.match "checkbox" button_group_classes << "input-group" end button_group_classes << (form.object.validated? ? "has-validation" : "") button_group_classes << "form-#{form_field}-input-group" # Non renderizziamo il contenuto del label in questa vista se siamo nello switch if content.match "form-switch" label_content = nil else label_content = form.label(form_field, class: ["form-label", "form-#{form_field}-label"]) end %> <%= label_content %> <%= content_tag :div, class: button_group_classes.join(" ") do %> <%= render partial: "editing_form_measure_unit", locals: {object: form.object, field: form_field} %> <%= content %> <%= error_messages_for(form.object, form_field) %> <% end %> <%= render partial: "editing_form_help_text", locals: {object: form.object, field: form_field} %>
Version data entries
5 entries across 5 versions & 1 rubygems