Files
@ 1886323d7431
Branch filter:
Location: symposion_app/pinaxcon/templates/forms/render.html - annotation
1886323d7431
1.4 KiB
text/html
Bootstrapification
Boot custom CSS, and put some base, standard css in its place.
Shame I did not start with fresh Bootstrap4, but oh well.
Some more templates could be made to make this less messy, which would
be good.
Boot custom CSS, and put some base, standard css in its place.
Shame I did not start with fresh Bootstrap4, but oh well.
Some more templates could be made to make this less messy, which would
be good.
a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c a3474fd9cd4c | {% load formset_tags %}
{% if form.total_form_count and form.empty_form %}
{% comment %}This is a formset.{% endcomment %}
<div class="formset" data-formset-prefix="{{ form.prefix }}">
{{ form.management_form }}
<div data-formset-body>
{% for inner_form in form %}
<div data-formset-form>
<fieldset>
{% include "forms/render_fields.html" with form=inner_form %}
</fieldset>
</div>
{% if not forloop.last %}
<div class="vertical-small"></div>
{% endif %}
{% endfor %}
</div>
<script type="form-template" data-formset-empty-form>
{% escapescript %}
<div class="vertical-small"></div>
<div data-formset-form>
<fieldset>
{% include "forms/render_fields.html" with form=form.empty_form %}
</fieldset>
</div>
{% endescapescript %}
</script>
<div class="vertical-small"></div>
<input type="button" class="btn" value="Add another" data-formset-add>
<script type="text/javascript">
function defer() {
if (window.jQuery) {
jQuery(function($) {
$(".formset").formset({
animateForms: true
});
});
} else {
setTimeout(function() { defer() }, 50);
}
}
defer();
</script>
</div>
{% else %}
{% include "forms/render_fields.html" %}
{% endif %}
|