laravel-datatables icon indicating copy to clipboard operation
laravel-datatables copied to clipboard

How can append a row for "Total" of some columns which that row should be excluded in search and sort ?

Open salmanulfaris opened this issue 2 years ago • 1 comments

Appending Aggregate row at last

I need to append a row which is the sum of numeric values of specific column. if i'm adding a row manually, it is included in sorting and searching (this also method doesn't work with pagination.)

is there any way to exclude specific row from searching and sorting ?

image

Code snippet of problem

  • PHP Version 8.0.10
  • Laravel Version 8.83.7
  • Laravel-Datatables Version 9.19.1

Thank You !

salmanulfaris avatar Jul 18 '22 12:07 salmanulfaris

You can use withQuery to calculate the filtered sum then use the json response to display the value every drawCallback.

yajra avatar Jul 19 '22 08:07 yajra

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] avatar Oct 08 '22 02:10 github-actions[bot]

This issue was closed because it has been inactive for 7 days since being marked as stale.

github-actions[bot] avatar Oct 16 '22 00:10 github-actions[bot]