Skip to content

Commit 63d9d66

Browse files
authored
Merge pull request #513 from patriciomacadden/fix-hardcoded-attribute
Fix hardcoded attribute in form
2 parents 93b0b4e + 91a67e9 commit 63d9d66

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/generators/tailwindcss/scaffold/templates/_form.html.erb.tt

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<%%= form.password_field :password_confirmation, class: ["block shadow-sm rounded-md border px-3 py-2 mt-2 w-full", {"border-gray-400 focus:outline-blue-600": <%= model_resource_name %>.errors[:password_confirmation].none?, "border-red-400 focus:outline-red-600": <%= model_resource_name %>.errors[:password_confirmation].any?}] %>
2424
<% elsif attribute.attachments? -%>
2525
<%%= form.label :<%= attribute.column_name %> %>
26-
<%%= form.<%= attribute.field_type %> :<%= attribute.column_name %>, multiple: true, class: ["block shadow-sm rounded-md border px-3 py-2 mt-2 w-full", {"border-gray-400 focus:outline-blue-600": <%= model_resource_name %>.errors[:password].none?, "border-red-400 focus:outline-red-600": <%= model_resource_name %>.errors[:password].any?}] %>
26+
<%%= form.<%= attribute.field_type %> :<%= attribute.column_name %>, multiple: true, class: ["block shadow-sm rounded-md border px-3 py-2 mt-2 w-full", {"border-gray-400 focus:outline-blue-600": <%= model_resource_name %>.errors[:<%= attribute.column_name %>].none?, "border-red-400 focus:outline-red-600": <%= model_resource_name %>.errors[:<%= attribute.column_name %>].any?}] %>
2727
<% else -%>
2828
<%%= form.label :<%= attribute.column_name %> %>
2929
<% if attribute.field_type == :textarea || attribute.field_type == :text_area -%>

0 commit comments

Comments
 (0)