Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Make the add weight link open in a JQuery modal dialog too

Roland Geider65f0141f7582
diff --git a/weight/templates/weight_overview.html b/weight/templates/weight_overview.html
index 7893d38b9..7a6a47c3a 100644
--- a/weight/templates/weight_overview.html
+++ b/weight/templates/weight_overview.html
@@ -29,13 +29,8 @@ function getDate(d) {
$(document).ready(function () {
-// Initialise a modal dialog
- $("#ajax-info").dialog({
- autoOpen: false,
- width: 600,
- modal: true,
- position: 'top'
- });
+ // Init the modal dialog
+ form_modal_dialog();
var data = {{chart_data|safe}};
@@ -132,7 +127,7 @@ $('circle').click(function(e) {
<div id="weight_diagram"></div>
<p>
-<a href="{% url weight.views.add None %}">{% trans "Add weight entry" %}</a>
+<a href="{% url weight.views.add None %}" class="modal-dialog">{% trans "Add weight entry" %}</a>
</p>
<p>