30 lines
820 B
Plaintext
30 lines
820 B
Plaintext
<%= form_for(@certification) do |f| %>
|
|
<% if @certification.errors.any? %>
|
|
<div id="error_explanation">
|
|
<h2><%= pluralize(@certification.errors.count, "error") %> prohibited this certification from being saved:</h2>
|
|
|
|
<ul>
|
|
<% @certification.errors.full_messages.each do |msg| %>
|
|
<li><%= msg %></li>
|
|
<% end %>
|
|
</ul>
|
|
</div>
|
|
<% end %>
|
|
|
|
<div class="field">
|
|
<%= f.label :name %><br />
|
|
<%= f.text_field :name %>
|
|
</div>
|
|
<div class="field">
|
|
<%= f.label :description %><br />
|
|
<%= f.text_area :description %>
|
|
</div>
|
|
<% f.fields_for :users do |u| %>
|
|
<%= u.label :user %><br />
|
|
<%= collection_select(:certifications_users, :user_id, User.all.sort_by(&:name), :id, :name) %>
|
|
<% end %>
|
|
<div class="actions">
|
|
<%= f.submit %>
|
|
</div>
|
|
<% end %>
|