From b6b14f6f1c16442555587fecdecc108e4de03085 Mon Sep 17 00:00:00 2001 From: Adarnof Date: Thu, 22 Feb 2018 13:06:07 -0500 Subject: [PATCH] Ensure all columns are perfectly aligned. Prevent sorting/searching portraits and killboard links. Default sorting to character names. --- .../templates/corputils/corpstats.html | 30 ++++++++++++++----- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/allianceauth/corputils/templates/corputils/corpstats.html b/allianceauth/corputils/templates/corputils/corpstats.html index dca15cf6..f0e78ce3 100644 --- a/allianceauth/corputils/templates/corputils/corpstats.html +++ b/allianceauth/corputils/templates/corputils/corpstats.html @@ -77,10 +77,10 @@ {% endif %} - {{ alt.character_name }} - {{ alt.corporation_name }} - {{ alt.alliance_name }} - + {{ alt.character_name }} + {{ alt.corporation_name }} + {{ alt.alliance_name }} + {% trans "Killboard" %} @@ -175,9 +175,25 @@ {% endblock %} {% block extra_script %} $(document).ready(function(){ - $('#table-mains').DataTable(); - $('#table-members').DataTable(); - $('#table-unregistered').DataTable(); + $('#table-mains').DataTable({ + "columnDefs": [ + { "sortable": false, "targets": [1] }, + ], + }); + $('#table-members').DataTable({ + "columnDefs": [ + { "searchable": false, "targets": [0, 2] }, + { "sortable": false, "targets": [0, 2] }, + ], + "order": [[ 1, "asc" ]], + }); + $('#table-unregistered').DataTable({ + "columnDefs": [ + { "searchable": false, "targets": [0, 2] }, + { "sortable": false, "targets": [0, 2] }, + ], + "order": [[ 1, "asc" ]], + }); }); {% endblock %} \ No newline at end of file