Unable to calculate the sum of the columns in each page when pagination is other than 10

Unable to calculate the sum of the columns in each page when pagination is other than 10

rakesh2020rakesh2020 Posts: 7Questions: 2Answers: 0

Link to test case: https://github.com/Rakesh-Srinivasa/leadlogistics_latest
Debugger code (debug.datatables.net):
Error messages shown: NA
Description of problem:

please check the file user_list.html in the git repository

you can also login to this url "http://rakesh1986.pythonanywhere.com/leadlogisticsApp/search/"

There are 2 issues here.

1.Unable to calculate the sum of individual columns,here the issue is,if the pagination is set to 10, then only for the 1st page it works,but if we increase the pagination to 25 or go to the next page the "Total "still displays the sum of 1st 10 entries only.

2.when tried to add buttons for csv,pdf etc,the buttons didn't show up.

code snippet:

$(document).ready(function() { $('#datatable_id').DataTable( { // dom: 'Bfrtip', // buttons: [ // 'copyHtml5', 'csvHtml5', 'excelHtml5', 'pdfHtml5' // ] } ); } );

Answers

This discussion has been closed.