Generate geojson in javascript

This commit is contained in:
Jonny Barnes 2017-06-17 11:49:47 +01:00
parent 0a621cd021
commit c17ef7d927
3 changed files with 42 additions and 30 deletions

View file

@ -27,7 +27,10 @@
</div>
</div>
@if ($note->placeLink)
<div class="map" data-latitude="{{ $note->latitude }}" data-longitude="{{ $note->longitude }}" data-id="{{ $note->nb60id }}"></div>
<script>var geojson{{ $note->nb60id }} = {!! $note->geoJson !!};</script>
<div class="map"
data-latitude="{{ $note->latitude }}"
data-longitude="{{ $note->longitude }}"
data-name="{{ $note->place->name }}"
data-marker="{{ $note->place->icon }}"></div>
@endif
</div>