aboutsummaryrefslogtreecommitdiff
path: root/design/templates/notes/partials/notebook_form.html
blob: 1e51e9c50a47f3cf5f03131ea19c66427f4abf31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<form id="nb-create-form" action="{{url}}" method="POST">{% csrf_token %}
    <div class="alert" id="non-field-errors">{{ form.non_field_errors }}</div>
            <div class="flex-wrapper flex-inner">
                {% for field in form %}{% if field.name == 'color_rgb' %}
                <fieldset class="fe-color-picker color-picker-fieldset block" id="color-picker" {% if form.instance.color_rgb %}style="background-color: {{form.instance.color_rgb}}; border: none;"{%endif%}>
                    {{field.label_tag}}
                    <input type="text" name="color_rgb" value="{{form.instance.color_rgb}}" maxlength="20" id="id_color_rgb">
                    {% if field.errors %}{{field.errors}}{% endif %}
                </fieldset>{% else %}
                {%if field.name != 'owner' %}<fieldset class="nb-{{field.name}}">
                    {{field.label_tag}}
                    {{field}}
                    {% if field.errors %}{{field.errors}}{% endif %}
                </fieldset>{%else%}{{field}}{% endif %}{%endif%}
                    {% endfor %}
                    <h1 class="notebook-title" id="nb-title">{{object.name}}</h1>
            </div>
                <input id="notebook-form-submit" name="create" type="submit" class="btn sm" value="Save" >
        </form>