Added a page & table for viewing a list of installed tasks
This commit is contained in:
49
templates/tables/tasks.html.twig
Normal file
49
templates/tables/tasks.html.twig
Normal file
@@ -0,0 +1,49 @@
|
||||
{# This partial template renders a table of permissions, to be populated with rows via an AJAX request.
|
||||
# This extends a generic template for paginated tables.
|
||||
#
|
||||
# Note that this template contains a "skeleton" table with an empty table body, and then a block of Handlebars templates which are used
|
||||
# to render the table cells with the data from the AJAX request.
|
||||
#}
|
||||
|
||||
{% extends "tables/table-paginated.html.twig" %}
|
||||
|
||||
{% block table %}
|
||||
<table id="{{table.id}}" class="tablesorter table table-bordered table-hover table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th data-column-name="name" data-priority="1">{{translate('NAME')}}</th>
|
||||
<th data-column-name="sprinkle" data-priority="1">{{translate('SPRINKLE')}}</th>
|
||||
<th data-column-name="schedule" data-priority="1">{{translate('SCHEDULE')}}</th>
|
||||
<th data-column-name="next_run" data-priority="1">{{translate('NEXT_RUN_TIME')}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for task in tasks %}
|
||||
<tr>
|
||||
<td data-text="{{task.sprinkle}}/{{task.name}}">
|
||||
<div>
|
||||
<strong>
|
||||
<!--<a href="{{site.uri.public}}/tasks/t/{{task.sprinkle}}/{{task.name}}">{{task.name}}</a>-->
|
||||
{{task.name}}
|
||||
</strong>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<td data-text="{{task.sprinkle}}">
|
||||
{{task.sprinkle}}
|
||||
</td>
|
||||
|
||||
<td data-text="{{task.schedule}}">
|
||||
<i class="text-muted" style="min-width: 70px; display: inline-block">({{task.schedule}})</i> {{task.schedule | formatCron()}}
|
||||
</td>
|
||||
|
||||
<td data-text="{{task.next_run}}">
|
||||
{{ task.next_run | format_datetime(pattern='HH:mm:ss dd/MM/yyyy') }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endblock %}
|
||||
|
||||
{% block table_pager_controls %}{% endblock %}
|
||||
Reference in New Issue
Block a user