Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
26 lines (24 sloc) 941 Bytes
%script
var bootstrapOccasions = [];
%h2= @event.name
.description= @event.description
%div#map.twelve.columns.alpha
%ul#occasionsList.four.columns.omega
- for occasion in @event.occasions
%script
bootstrapOccasions.push(new App.Occasion({ latitude: "#{occasion.latitude}", longitude: "#{occasion.longitude}", note: "#{occasion.note}", occurred_at: "#{occasion.occurred_at}", _id: "#{occasion._id}", }));
%li
= render :partial => "occasions/occasion", :locals => {:occasion => occasion}
%div.clear
%div.edit_occasion{ :style => "display:none"}
= form_for [@event, current_user.events.find(@event.id).occasions.build()] do |f|
%div.coordinate_input
= f.hidden_field :latitude
%div.coordinate_input
= f.hidden_field :longitude
%div.date_field
= f.hidden_field :occurred_at
%div.note_field
= f.label :note
= f.text_area :note
= f.submit "Add"