Skip to content
Snippets Groups Projects
Commit eed4c3f6 authored by Todd Dembrey's avatar Todd Dembrey
Browse files

Move the base js so that we dont get conflicts with jquery on load

parent 5e23f825
No related branches found
No related tags found
No related merge requests found
...@@ -6,7 +6,7 @@ from django.utils.translation import ugettext_lazy as _ ...@@ -6,7 +6,7 @@ from django.utils.translation import ugettext_lazy as _
from addressfield.fields import AddressField from addressfield.fields import AddressField
from opentech.apply.categories.blocks import CategoryQuestionBlock from opentech.apply.categories.blocks import CategoryQuestionBlock
from opentech.apply.stream_forms.blocks import FormFieldsBlock from opentech.apply.stream_forms.blocks import FormFieldsBlock
from opentech.apply.utils.blocks import MustIncludeFieldBlock, CustomFormFieldsBlock from opentech.apply.utils.blocks import MustIncludeFieldBlock, CustomFormFieldsBlock, RichTextFieldBlock
class ApplicationMustIncludeFieldBlock(MustIncludeFieldBlock): class ApplicationMustIncludeFieldBlock(MustIncludeFieldBlock):
...@@ -103,6 +103,7 @@ class DurationBlock(ApplicationMustIncludeFieldBlock): ...@@ -103,6 +103,7 @@ class DurationBlock(ApplicationMustIncludeFieldBlock):
class ApplicationCustomFormFieldsBlock(CustomFormFieldsBlock, FormFieldsBlock): class ApplicationCustomFormFieldsBlock(CustomFormFieldsBlock, FormFieldsBlock):
category = CategoryQuestionBlock(group=_('Custom')) category = CategoryQuestionBlock(group=_('Custom'))
rich_text = RichTextFieldBlock(group=_('Fields'))
required_blocks = ApplicationMustIncludeFieldBlock.__subclasses__() required_blocks = ApplicationMustIncludeFieldBlock.__subclasses__()
......
...@@ -25,12 +25,13 @@ ...@@ -25,12 +25,13 @@
<div> <div>
<form class="form" action="" method="post" enctype="multipart/form-data"> <form class="form" action="" method="post" enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
{{ form.media }}
{% for field in form %} {% for field in form %}
{% if field.field %} {% if field.field %}
{% include "funds/includes/field.html" %} {% include "funds/includes/field.html" %}
{% else %} {% else %}
{{ field }} {{ field }}
{% endif %} {% endif %}
{% endfor %} {% endfor %}
{% for button_name, button_value in buttons %} {% for button_name, button_value in buttons %}
...@@ -47,7 +48,3 @@ ...@@ -47,7 +48,3 @@
</div> </div>
{% endblock %} {% endblock %}
{% block extra_js %}
{{ form.media }}
{% endblock %}
...@@ -29,6 +29,8 @@ ...@@ -29,6 +29,8 @@
<link rel="stylesheet" type="text/css" href="{% static 'css/apply/main.css' %}"> <link rel="stylesheet" type="text/css" href="{% static 'css/apply/main.css' %}">
{# Hijack styling #} {# Hijack styling #}
<link rel="stylesheet" type="text/css" href="{% static 'hijack/hijack-styles.css' %}" /> <link rel="stylesheet" type="text/css" href="{% static 'hijack/hijack-styles.css' %}" />
<script type="text/javascript" src="{% static 'js/main.js' %}"></script>
</head> </head>
<body class="{% block body_class %}light-grey-bg template-{{ page.get_verbose_name|slugify }}{% endblock %}"> <body class="{% block body_class %}light-grey-bg template-{{ page.get_verbose_name|slugify }}{% endblock %}">
...@@ -93,8 +95,6 @@ ...@@ -93,8 +95,6 @@
</main> </main>
<footer class="footer"></footer> <footer class="footer"></footer>
<script type="text/javascript" src="{% static 'js/main.js' %}"></script>
{% block extra_js %}{% endblock %} {% block extra_js %}{% endblock %}
</body> </body>
</html> </html>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment