%= form_for(@mac) do |f| %>
<% if @mac.errors.any? %>
<%= pluralize(@mac.errors.count, "error") %> prohibited this Mac from being saved:
<% @mac.errors.full_messages.each do |msg| %>
- <%= msg %>
<% end %>
<% end %>
<%= f.label :user_id, "User" %>
<%= collection_select(:mac, :user_id, @users, :id, :name) %>
<%= f.label :mac, "Mac" %>
<%= f.text_field :mac %>
<%= f.submit %>
<% end %>