Update to follow django-chickpea changes
This commit is contained in:
parent
0cce7f9e2a
commit
4220a2df1d
4 changed files with 22 additions and 24 deletions
|
@ -1,6 +1,13 @@
|
|||
YouMap project
|
||||
==============
|
||||
|
||||
About
|
||||
-----
|
||||
YouMap let you create map with OpenStreetMap layers in a minute and embed them in your site.
|
||||
*Be cause we think that the more OSM will be used, the more OSM will be **cured**.*
|
||||
It uses django-chickpea, built on top of Django and Leaflet
|
||||
|
||||
|
||||
Quickstart
|
||||
----------
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.js"></script>
|
||||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.mediaQueryToggle.js"></script>
|
||||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.reveal.js"></script>
|
||||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.orbit.js"></script>
|
||||
<!--script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.orbit.js"></script-->
|
||||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.navigation.js"></script>
|
||||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.buttons.js"></script>
|
||||
<script src="{{ STATIC_URL }}foundation/javascripts/jquery.foundation.tabs.js"></script>
|
||||
|
@ -40,22 +40,24 @@
|
|||
{% block bottom_js %}
|
||||
<script type="text/javascript">
|
||||
$(document).foundationAlerts();
|
||||
L.Util.chickpea_modal = function (content, context) {
|
||||
L.Chickpea.on('modal_ready', function (e) {
|
||||
var $div = $('#reveal-container');
|
||||
// reset class
|
||||
$div.attr("class", "");
|
||||
$div.addClass("reveal-modal");
|
||||
if (context && context.class) {
|
||||
$div.addClass(context.class);
|
||||
if (e.cssClass) {
|
||||
$div.addClass(e.cssClass);
|
||||
}
|
||||
return $div.empty().html(content).append('<a class="close-reveal-modal">×</a>').reveal();
|
||||
};
|
||||
L.Util.chickpea_alert = function (content, level, context) {
|
||||
console.log("alert", content);
|
||||
$div = $('<div>').addClass('alert-box success global').html(content);
|
||||
return $div.empty().html(e.data.html).append('<a class="close-reveal-modal">×</a>').reveal();
|
||||
});
|
||||
L.Chickpea.on('modal_close', function (e) {
|
||||
var $div = $('#reveal-container').trigger('reveal:close');
|
||||
});
|
||||
L.Chickpea.on('alert', function (e) {
|
||||
$div = $('<div>').addClass('alert-box success global').html(e.content);
|
||||
$div.append('<a href="#" class="close">×</a>');
|
||||
$("body").prepend($div);
|
||||
};
|
||||
});
|
||||
$('a.reveal').click(function(e) {
|
||||
e.preventDefault();
|
||||
var $this = $(this);
|
||||
|
|
|
@ -8,6 +8,8 @@
|
|||
{% endfor %}
|
||||
{{ form.description }}
|
||||
{{ form.description.errors }}
|
||||
{{ form.licence }}
|
||||
{{ form.licence.errors }}
|
||||
{{ form.zoom }}
|
||||
{{ form.center }}
|
||||
<input type="submit" class="button" />
|
||||
|
|
|
@ -144,17 +144,4 @@
|
|||
|
||||
<!-- End Footer -->
|
||||
<!-- Included JS Files -->
|
||||
{% endblock content %}
|
||||
|
||||
|
||||
{% block bottom_js %}
|
||||
{{ block.super }}
|
||||
<script type="text/javascript">
|
||||
$(window).load(function() {
|
||||
$('#featured').orbit({
|
||||
fluid: '2x1',
|
||||
timer: false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{% endblock bottom_js %}
|
||||
{% endblock content %}
|
Loading…
Reference in a new issue