<%= form_for bubble, url: bubble.persisted? ? bubble_path(bubble) : bubbles_path do |f| %>
<%= f.label :name, "Nom" %> <%= f.text_field :name, required: true %>
<%= f.label :description, "Description" %> <%= f.text_area :description %>
<%= f.label :color, "Couleur" %> <%= f.color_field :color %>
<%= f.label :owner_id, "Administrateur" %> <%= f.select :owner_id, User.all.collect {|u| [ u.email, u.id ] }, selected: bubble.owner_id || current_user.id %>
<%= f.submit "Sauvegarder" %> <% end %>