Simplify generating form fields with labels
Instead of generating the label and then a field without a label, we can directly generate a field with a label.
This commit is contained in:
@@ -27,10 +27,9 @@
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<%= f.label :publication_date, t("tracking.milestones.new.date") %>
|
||||
<%= f.text_field :publication_date,
|
||||
value: @milestone.publication_date.present? ? l(@milestone.publication_date.to_date) : nil,
|
||||
label: false,
|
||||
label: t("tracking.milestones.new.date"),
|
||||
class: "js-calendar-full" %>
|
||||
|
||||
<%= render "images/admin_image", imageable: @milestone, f: f %>
|
||||
|
||||
Reference in New Issue
Block a user