$('#routes_table').dataTable( {
"bJQueryUI": true,
+ "aoColumns": [
+ {"bVisible": false, "bSearchable": false,"bSortable": false },
+ {"bSearchable": true,"bSortable": true},
+ {"bSearchable": true,"bSortable": true},
+ {"bSearchable": true,"bSortable": true},
+ {"bSearchable": true,"bSortable": true},
+ {"bSearchable": true,"bSortable": true},
+ {"bSearchable": true,"bSortable": true},
+ {"bSearchable": true,"bSortable": true},
+ {"bVisible": true, "bSearchable": false,"bSortable": false}
+ ],
+ "aaSorting": [[0,'desc']],
"oLanguage": {
- "sLengthMenu": '{% trans "Display" %} <select><option value="25">25</option><option value="50">50</option><option value="-1">{% trans "All" %}</option></select> routes'
+ "sLengthMenu": '{% trans "Display" %} <select><option value="25">25</option><option value="50">50</option><option value="-1">{% trans "All" %}</option></select> rules'
},
"iDisplayLength": 25,
} );
</style>
{% endblock %}
-{% block title %}{% trans "My routes" %}{% endblock %}
+{% block title %}{% trans "My rules" %}{% endblock %}
{% block content %}
<div style="float:left">
- <h3 style="margin-top: 0px;">{% trans "My routes" %}</h3>
+ <h3 style="margin-top: 0px;">{% trans "My rules" %}</h3>
</div>
<div class='button_place' style="float:right">
- <button id="consolebutton">Console</button> <a href="{% url add-route %}" id="routebutton">Add Route</a>
+ <button id="consolebutton">Console</button> <a href="{% url add-route %}" id="routebutton">Add Rule</a>
</div>
<table class="display" width="100%" id="routes_table">
<thead>
<tr>
+ <th>Id</th>
<th>{% trans "Name" %}</th>
<th>{% trans "Match" %}</th>
<th style="text-align: center;">{% trans "Then" %}</th>
<th style="text-align: center;">{% trans "Applier" %}</th>
<th style="text-align: center;">{% trans "Expires" %}</th>
<th style="text-align: center;">{% trans "Response" %}</th>
- <th style="text-align: center; width:140px;">{% trans "Actions" %}</th>
+ <th style="text-align: center; width:130px;">{% trans "Actions" %}</th>
</tr>
</thead>
{% for route in routes %}
<tr {% ifequal route.status 'ACTIVE' %} class="GradeA" {% else %} class="GradeX" {% endifequal %}>
+ <td>{{ route.pk }}</td>
<td>{{ route.name }}</td>
<td>{{ route.get_match|safe|escape }}</td>
<td style="text-align: center;">{{route.get_then|safe|escape}}</td>
<td style="text-align: center;">{{ route.applier }}</td>
<td style="text-align: center;">{{ route.expires }}</td>
<td style="text-align: center;">{{ route.response }}</td>
- <td style="text-align: center;">
+ <td style="text-align: center; width:140px;">
{% ifequal route.status 'ACTIVE' %}
<a href="{% url edit-route route.name %}" class="edit_button" id="edit_button_{{route.pk}}">Edit</a>
<button class="del_button" id="{{route.name}}" onclick="javascript:delete_route(this.id)">Del</button>
</table>
<div id="dialog" title="Delete Route">
- <p>You are about to delete route <strong><span id="route_to_delete"></span></strong></p>
- <p>Deleting the route will automatically remove the configuration from the network and mark this route as inactive.</p>
+ <p>You are about to delete rule <strong><span id="route_to_delete"></span></strong></p>
+ <p>Deleting the rule will automatically remove the configuration from the network and mark this route as inactive.</p>
<p>Are you sure you want to proceed?</p>
</div>
<div id="console" title="Console">