Files
parse/app/views/subprojects/_form.html.erb
2025-07-23 11:37:49 +02:00

25 lines
627 B
Plaintext

<%= form_with(model: subproject) do |form| %>
<% if subproject.errors.any? %>
<div style="color: red">
<h2><%= pluralize(subproject.errors.count, "error") %> prohibited this subproject from being saved:</h2>
<ul>
<% subproject.errors.each do |error| %>
<li><%= error.full_message %></li>
<% end %>
</ul>
</div>
<% end %>
<% subproject_form_fields.each do |attrib| %>
<div>
<%= form.label attrib, style: "display: block" %>
<%= form.text_field attrib, value: subproject.send(attrib) %>
</div>
<% end %>
<div>
<%= form.submit %>
</div>
<% end %>