added the last two models
This commit is contained in:
27
app/views/credentials/_form.html.erb
Normal file
27
app/views/credentials/_form.html.erb
Normal file
@@ -0,0 +1,27 @@
|
||||
<%= form_with(model: credential) do |form| %>
|
||||
<% if credential.errors.any? %>
|
||||
<div style="color: red">
|
||||
<h2><%= pluralize(credential.errors.count, "error") %> prohibited this credential from being saved:</h2>
|
||||
|
||||
<ul>
|
||||
<% credential.errors.each do |error| %>
|
||||
<li><%= error.full_message %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<div>
|
||||
<%= form.label :email, style: "display: block" %>
|
||||
<%= form.text_field :email %>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<%= form.label :password, style: "display: block" %>
|
||||
<%= form.text_field :password %>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<%= form.submit %>
|
||||
</div>
|
||||
<% end %>
|
||||
Reference in New Issue
Block a user