changeset 6877:c5bff92d5084

templates: disable paging and page size controls in DataTables Since all data is sent to the client side, it can just as well be rendered. PageDown or scrolling is more convenient for paging than paging buttons, so short of "infinite scrolling", showing all entries is an acceptable solution ... especially when it very rarely is hundres of entries. There could perhaps be further changes to how DataTables is shown - this is one step.
author Mads Kiilerich <mads@kiilerich.com>
date Thu, 14 Sep 2017 02:08:06 +0200
parents 6db3122e4d75
children 1ba4fee6b27c
files kallithea/templates/admin/my_account/my_account_repos.html kallithea/templates/admin/my_account/my_account_watched.html kallithea/templates/admin/repo_groups/repo_groups.html kallithea/templates/admin/repos/repos.html kallithea/templates/admin/user_groups/user_groups.html kallithea/templates/admin/users/users.html kallithea/templates/index_base.html
diffstat 7 files changed, 14 insertions(+), 14 deletions(-) [+]
line wrap: on
line diff
--- a/kallithea/templates/admin/my_account/my_account_repos.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/admin/my_account/my_account_repos.html	Thu Sep 14 02:08:06 2017 +0200
@@ -16,7 +16,7 @@
             {data: "action", title: ${h.jshtml(_('Action'))}, sortable: false, searchable: false}
         ],
         order: [[2, "asc"]],
-        dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-        pageLength: 100
+        dom: '<"dataTables_left"f><"dataTables_right"i>t',
+        paging: false,
     });
 </script>
--- a/kallithea/templates/admin/my_account/my_account_watched.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/admin/my_account/my_account_watched.html	Thu Sep 14 02:08:06 2017 +0200
@@ -15,7 +15,7 @@
             {data: "last_changeset", "orderData": 3, title: ${h.jshtml(_('Tip'))}, searchable: false},
         ],
         order: [[2, "asc"]],
-        dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-        pageLength: 100
+        dom: '<"dataTables_left"f><"dataTables_right"i>t',
+        paging: false,
     });
 </script>
--- a/kallithea/templates/admin/repo_groups/repo_groups.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/admin/repo_groups/repo_groups.html	Thu Sep 14 02:08:06 2017 +0200
@@ -43,8 +43,8 @@
             {data: "action", title: ${h.jshtml(_('Action'))}, sortable: false, searchable: false}
         ],
         drawCallback: updateRowCountCallback($("#repo_group_count")),
-        dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-        pageLength: 100
+        dom: '<"dataTables_left"f><"dataTables_right"i>t',
+        paging: false,
     });
 
 </script>
--- a/kallithea/templates/admin/repos/repos.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/admin/repos/repos.html	Thu Sep 14 02:08:06 2017 +0200
@@ -44,8 +44,8 @@
             {data: "action", title: ${h.jshtml(_('Action'))}, sortable: false, searchable: false}
         ],
         drawCallback: updateRowCountCallback($("#repo_count")),
-        dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-        pageLength: 100
+        dom: '<"dataTables_left"f><"dataTables_right"i>t',
+        paging: false,
     });
 </script>
 
--- a/kallithea/templates/admin/user_groups/user_groups.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/admin/user_groups/user_groups.html	Thu Sep 14 02:08:06 2017 +0200
@@ -43,8 +43,8 @@
             {data: "action", title: ${h.jshtml(_('Action'))}, searchable: false, sortable: false}
         ],
         order: [[1, "asc"]],
-        dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-        pageLength: 100
+        dom: '<"dataTables_left"f><"dataTables_right"i>t',
+        paging: false,
     });
 </script>
 </%def>
--- a/kallithea/templates/admin/users/users.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/admin/users/users.html	Thu Sep 14 02:08:06 2017 +0200
@@ -46,8 +46,8 @@
         ],
         order: [[1, "asc"]],
         drawCallback: updateRowCountCallback($("#user_count")),
-        dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-        pageLength: 100
+        dom: '<"dataTables_left"f><"dataTables_right"i>t',
+        paging: false,
     });
 </script>
 
--- a/kallithea/templates/index_base.html	Thu Sep 14 02:08:06 2017 +0200
+++ b/kallithea/templates/index_base.html	Thu Sep 14 02:08:06 2017 +0200
@@ -64,7 +64,7 @@
                     {data: "atom", defaultContent: '', sortable: false}
                 ],
                 order: [[1, "asc"]],
-                dom: '<"dataTables_left"f><"dataTables_right"ilp>t',
-                pageLength: 100
+                dom: '<"dataTables_left"f><"dataTables_right"i>t',
+                paging: false,
             });
       </script>