demarches-normaliennes/app/views/champs/carte/show.js.erb

12 lines
449 B
Text
Raw Normal View History

<%= render_flash(timeout: 5000, fixed: true) %>
2018-10-17 12:02:34 +02:00
<%= render_to_element("#{@selector} + .geo-areas",
partial: 'shared/champs/carte/geo_areas',
locals: { champ: @champ, error: @error }) %>
<% if feature_enabled?(:new_map_editor) %>
<%= fire_event('map:update', { featureCollection: @champ.to_feature_collection }.to_json) %>
<% else %>
<%= fire_event('carte:update', { selector: @selector, data: @champ.to_render_data }.to_json) %>
<% end %>