mirror of
https://github.com/flextype/flextype.git
synced 2025-08-18 02:41:27 +02:00
23
site/plugins/admin/views/templates/extends/themes/index.html
Normal file
23
site/plugins/admin/views/templates/extends/themes/index.html
Normal file
@@ -0,0 +1,23 @@
|
||||
{% extends "plugins/admin/views/partials/base.html" %}
|
||||
|
||||
{% block content %}
|
||||
{% if (themes_list|length > 0) %}
|
||||
<div class="card-deck">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
Default
|
||||
</div>
|
||||
<img src="{{ base_url() }}/site/themes/default/preview.png" class="card-img-top" alt="...">
|
||||
<div class="card-footer">
|
||||
<small class="text-muted text-center">Active theme</small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
|
||||
{% endif %}
|
||||
{% endblock %}
|
@@ -12,76 +12,76 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
{% if templates_list|length > 0 %}
|
||||
{% for id in templates_list %}
|
||||
{% for template in templates_list %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{{ path_for('admin.templates.edit') }}?id={{ id }}&type=template">{{ id }}</a>
|
||||
<a href="{{ path_for('admin.templates.edit') }}?id={{ template.basename }}&type=template">{{ template.basename }}</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={{ id }}&type=template">{{ tr('admin_edit') }}</a>
|
||||
<a class="btn btn-default" href="{{ path_for('admin.templates.edit') }}?theme={{ theme }}&id={{ template.basename }}&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={{ id }}&type=template">{{ tr('admin_rename') }}</a>
|
||||
<a class="dropdown-item" href="{{ path_for('admin.templates.rename') }}?theme={{ theme }}&id={{ template.basename }}&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>
|
||||
document.getElementById('duplicate-template-id-{{ template.basename }}').submit();">{{ tr('admin_duplicate') }}</a>
|
||||
</div>
|
||||
</div>
|
||||
<form id="duplicate-template-id-{{ id }}" action="{{ path_for('admin.templates.duplicateProcess') }}" method="POST" style="display: none;">
|
||||
<form id="duplicate-template-id-{{ template.basename }}" action="{{ path_for('admin.templates.duplicateProcess') }}" method="POST" style="display: none;">
|
||||
{{ csrf() }}
|
||||
<input type="hidden" name="template-id" value="{{ id }}">
|
||||
<input type="hidden" name="template-id" value="{{ template.basename }}">
|
||||
<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;">
|
||||
<form id="delete-template-id-{{ template.basename }}" action="{{ path_for('admin.templates.deleteProcess') }}" method="POST" style="display: none;">
|
||||
{{ csrf() }}
|
||||
<input type="hidden" name="template-id" value="{{ id }}">
|
||||
<input type="hidden" name="template-id" value="{{ template.basename }}">
|
||||
<input type="hidden" name="type" value="template">
|
||||
</form>
|
||||
<a class="btn btn-default" href="javascript:;"
|
||||
onclick="event.preventDefault();
|
||||
document.getElementById('delete-template-id-{{ id }}').submit();">{{ tr('admin_delete') }}</a>
|
||||
document.getElementById('delete-template-id-{{ template.basename }}').submit();">{{ tr('admin_delete') }}</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if partials_list|length > 0 %}
|
||||
{% for id in partials_list %}
|
||||
{% for partial in partials_list %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{{ path_for('admin.templates.edit') }}?id={{ id }}&type=partial">{{ id }}</a>
|
||||
<a href="{{ path_for('admin.templates.edit') }}?id={{ partial.basename }}&type=partial">{{ partial.basename }}</a>
|
||||
</td>
|
||||
<td>{{ tr('admin_partial') }}</td>
|
||||
<td class="text-right">
|
||||
<div class="btn-group">
|
||||
<a class="btn btn-default" href="{{ path_for('admin.templates.edit') }}?id={{ id }}&type=partial">{{ tr('admin_edit') }}</a>
|
||||
<a class="btn btn-default" href="{{ path_for('admin.templates.edit') }}?id={{ partial.basename }}&type=partial">{{ 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={{ id }}&type=partial">{{ tr('admin_rename') }}</a>
|
||||
<a class="dropdown-item" href="{{ path_for('admin.templates.rename') }}?id={{ partial.basename }}&type=partial">{{ tr('admin_rename') }}</a>
|
||||
<a class="dropdown-item" href="javascript:;"
|
||||
onclick="event.preventDefault();
|
||||
document.getElementById('duplicate-partial-id-{{ id }}').submit();">{{ tr('admin_duplicate') }}</a>
|
||||
document.getElementById('duplicate-partial-id-{{ partial.basename }}').submit();">{{ tr('admin_duplicate') }}</a>
|
||||
</div>
|
||||
</div>
|
||||
<form id="duplicate-partial-id-{{ id }}" action="{{ path_for('admin.templates.duplicateProcess') }}" method="POST" style="display: none;">
|
||||
<form id="duplicate-partial-id-{{ partial.basename }}" action="{{ path_for('admin.templates.duplicateProcess') }}" method="POST" style="display: none;">
|
||||
{{ csrf() }}
|
||||
<input type="hidden" name="partial-id" value="{{ id }}">
|
||||
<input type="hidden" name="partial-id" value="{{ partial.basename }}">
|
||||
<input type="hidden" name="type" value="partial">
|
||||
</form>
|
||||
<form id="delete-partial-id-{{ id }}" action="{{ path_for('admin.templates.deleteProcess') }}" method="POST" style="display: none;">
|
||||
<form id="delete-partial-id-{{ partial.basename }}" action="{{ path_for('admin.templates.deleteProcess') }}" method="POST" style="display: none;">
|
||||
{{ csrf() }}
|
||||
<input type="hidden" name="partial-id" value="{{ id }}">
|
||||
<input type="hidden" name="partial-id" value="{{ partial.basename }}">
|
||||
<input type="hidden" name="type" value="partial">
|
||||
</form>
|
||||
<a class="btn btn-default" href="javascript:;"
|
||||
onclick="event.preventDefault();
|
||||
document.getElementById('delete-partial-id-{{ id }}').submit();">{{ tr('admin_delete') }}</a>
|
||||
document.getElementById('delete-partial-id-{{ partial.basename }}').submit();">{{ tr('admin_delete') }}</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
Reference in New Issue
Block a user