Commit 31f76d13 authored by Marc Ducobu's avatar Marc Ducobu
Browse files

updating js call - close #391

parent fdf6ac0b
......@@ -33,6 +33,6 @@
{% block js %}
<script type="text/javascript">
chill.protectUnsavedDataForFrom('form[name="{{ edit_form.vars.form.vars.name }}"]', '{{ "You are going to leave a page with unsubmitted data. Are you sure you want to leave ?"|trans }}');
chill.displayAlertWhenLeavingModifiedForm('form[name="{{ edit_form.vars.form.vars.name }}"]', '{{ "You are going to leave a page with unsubmitted data. Are you sure you want to leave ?"|trans }}');
</script>
{% endblock %}
......@@ -26,13 +26,12 @@
{{ form_widget(form) }}
<div class="grid-12 centered sticky-form-buttons">
<button class="sc-button green margin-10" type="submit"><i class="fa fa-save"></i> {{ 'Add report'|trans }}</button>
<button class="sc-button red margin-10" type="reset"><i class="fa fa-eraser"></i> {{ 'Reset report'|trans }}</button>
</div>
{{ form_end(form) }}
{% endblock %}
{% block js %}
<script type="text/javascript">
chill.protectUnsavedDataForFrom('form[name="{{ form.vars.form.vars.name }}"]', '{{ "You are going to leave a page with unsubmitted data. Are you sure you want to leave ?"|trans }}');
chill.displayAlertWhenLeavingUnsubmittedForm('form[name="{{ form.vars.form.vars.name }}"]', '{{ "You are going to leave a page with unsubmitted data. Are you sure you want to leave ?"|trans }}');
</script>
{% endblock %}
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment