mirror of
https://github.com/flextype/flextype.git
synced 2025-08-29 16:00:15 +02:00
- Templates Controller/Views implementation
This commit is contained in:
@@ -12,20 +12,20 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
{% if templates_list|length > 0 %}
|
||||
{% for template in templates_list %}
|
||||
{% for id in templates_list %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{{ path_for('admin.templates.edit') }}?id={{ template }}&type=template">{{ template }}</a>
|
||||
<a href="{{ path_for('admin.templates.edit') }}?id={{ id }}&type=template">{{ id }}</a>
|
||||
</td>
|
||||
<td>{{ tr('admin_template') }}</td>
|
||||
<td class="text-right">
|
||||
<div class="btn-group">
|
||||
<a class="btn btn-default" href="{{ path_for('admin.templates.edit') }}?id={{ template }}&type=template">{{ tr('admin_edit') }}</a>
|
||||
<a class="btn btn-default" href="{{ path_for('admin.templates.edit') }}?id={{ id }}&type=template">{{ tr('admin_edit') }}</a>
|
||||
<button type="button" class="btn btn-default dropdown-toggle dropdown-toggle-split" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span class="sr-only">Toggle Dropdown</span>
|
||||
</button>
|
||||
<div class="dropdown-menu">
|
||||
<a class="dropdown-item" href="{{ path_for('admin.templates.rename') }}?id={{ template }}&type=template"><?= __('admin_rename') ?></a>
|
||||
<a class="dropdown-item" href="{{ path_for('admin.templates.rename') }}?id={{ id }}&type=template">{{ tr('admin_rename') }}</a>
|
||||
<a class="dropdown-item" href="javascript:;"
|
||||
onclick="event.preventDefault();
|
||||
document.getElementById('duplicate-template-id-{{ id }}').submit();">{{ tr('admin_duplicate') }}</a>
|
||||
@@ -34,10 +34,12 @@
|
||||
<form id="duplicate-template-id-{{ id }}" action="{{ path_for('admin.templates.duplicateProcess') }}" method="POST" style="display: none;">
|
||||
{{ csrf() }}
|
||||
<input type="hidden" name="template-id" value="{{ id }}">
|
||||
<input type="hidden" name="type" value="template">
|
||||
</form>
|
||||
<form id="delete-template-id-{{ id }}" action="{{ path_for('admin.templates.deleteProcess') }}" method="POST" style="display: none;">
|
||||
{{ csrf() }}
|
||||
<input type="hidden" name="template-id" value="{{ id }}">
|
||||
<input type="hidden" name="type" value="template">
|
||||
</form>
|
||||
<a class="btn btn-default" href="javascript:;"
|
||||
onclick="event.preventDefault();
|
||||
|
Reference in New Issue
Block a user