ingang/app/views/rooms/_form.html.erb

38 lines
845 B
Plaintext

<%= form_with(model: room, local: true) do |form| %>
<% if room.errors.any? %>
<div id="error_explanation">
<h2><%= pluralize(room.errors.count, "error") %> prohibited this room from being saved:</h2>
<ul>
<% room.errors.full_messages.each do |message| %>
<li><%= message %></li>
<% end %>
</ul>
</div>
<% end %>
<div class="field">
<%= form.label :name %>
<%= form.text_field :name %>
</div>
<div class="field">
<%= form.label :meeting %>
<%= form.text_field :meeting %>
</div>
<div class="field">
<%= form.label :attendee_pw %>
<%= form.text_field :attendee_pw %>
</div>
<div class="field">
<%= form.label :moderator_pw %>
<%= form.text_field :moderator_pw %>
</div>
<div class="actions">
<%= form.submit %>
</div>
<% end %>