formspree/formspree/templates/forms/list-item.html

44 lines
2.1 KiB
HTML

<tr class="{% if form.counter == 0 %}new{% endif %} {% if form.confirmed %}verified{% elif form.confirm_sent %}waiting_confirmation{% endif %}">
<td data-label="Status">
<a href="#form-{{ form.hashid }}" class="no-underline">
{% if not form.host %}
<span class="tooltip hint--right" data-hint="New form. Place the code generated here in some page and submit it!"><span class="ion-help"></span></span>
{% elif form.confirmed %}
<span class="tooltip hint--right" data-hint="Form confirmed"><span class="ion-checkmark-round"></span></span>
{% elif form.confirm_sent %}
<span class="tooltip hint--right" data-hint="Waiting confirmation"><span class="ion-pause"></span></span>
{% endif %}
</a>
</td>
<td data-label="URL">
<a href="#form-{{ form.hashid }}" class="no-underline">
{% if not form.host %}
Waiting for a submission
{% else %}
{{ form.host }}
{% if form.sitewide %}
<span class="highlight tooltip hint--top" data-hint="This form works for all paths under {{ form.host }}/">/ *</span>
{% endif %}
{% endif %}
</a>
</td>
<td class="target-email" data-label="Target email address">
<a href="#form-{{ form.hashid }}" class="no-underline">
<span class="hint--top" data-hint="{{ request.url_root.replace('http://', 'https://') }}{% if form.hash %}{{ form.email }}{% else %}{{ form.hashid }}{% endif %}">{{ form.email }}</span>
</a>
</td>
<td class="n-submissions" data-label="Submissions counter">
<a href="{{ url_for('form-submissions', hashid=form.hashid) }}" class="no-underline">
{% if form.counter == 0 %}
<span class="never">never submitted</span>
{% else %}
{{ form.counter }} submissions
{% endif %}
</a>
</td>
<td data-label="Disable"><form method="POST" action="{{ url_for('form-toggle', hashid=form.hashid) }}"><button class="no-border"><i class="fa fa-{% if form.disabled %}lock{% else %}unlock{% endif %} fa-fw"></i></button></form></td>
<td data-label="Delete">
<a href="#delete-{{form.hashid}}" class="no-underline"><i class="fa fa-trash-o delete"></i></a>
</td>
</tr>