{% load i18n static %}
<div id="{{ model_name }}_edit_form" style="{% block form_style %}padding: 10px;{% endblock %}">
    {% block edit_form %}
    <form class="layui-form data-form" action="" method="post"  enctype="multipart/form-data">
        {% csrf_token %}
            {% for fieldset in adminform %}
              {% include "layui/includes/fieldset_3c.html" %}
            {% endfor %}
        {% block add_fields %}
        {% endblock %}
    </form>
    {% endblock %}
</div>
<script>
    layui.use(['form', 'laydate'], function() {
        var form = layui.form, laydate = layui.laydate;
        form.render();
        $("form.layui-form input.layui-datetime").each(function(){
            laydate.render({elem: this, type: 'datetime'});
        });
        $("form.layui-form input.layui-date").each(function(){
            laydate.render({elem: this, type: 'date'});
        });
        $("form.layui-form input.layui-time").each(function(){
            laydate.render({elem: this, type: 'time'});
        });
    });
</script>
