smartmetals / phoenix_datatables

Library to implement server-side API for the jQuery DataTables library with Elixir and Phoenix Framework
MIT License
14 stars 7 forks source link

Optimize Record Counts #17

Closed jeremyjh closed 6 years ago

jeremyjh commented 6 years ago

Adds support for total_entries option so the application can cache and provide the total entries so that the library doesn't have to run a counts query. Also if the search term is empty, we use the total count (however we got that) instead of running a "filtered" query that would be identical.