Topic: Datatable custom sort
Expected behaviorhttps://mdbootstrap.com/support/angular/custom-sorting-for-datatable/ORAllow us to override the default sort function within the column definition so that data can be formatted for users and also sorted based on the underlying data.
*Actual behavior*The current sort in place treats all data as a string. So $9.00 is seen as "greater" than $100.00; Dec 1, 2005 is "before" Feb 1 2030; enumerations cannot be sorted, formatted numbers cannot be sorted, any dates other than ISO cannot be sorted, etc.
*Resources (screenshots, code snippets etc.)*Your own demonstration of the datatable fails to correctly sort the salary column in the first example.
Grzegorz Bujański staff answered a year ago
Please note that DataTables.net is a table library and they only focus on that. MDB UI Kit as the name suggests is a UI kit. That is a collection of many components. We do not focus on creating one big and complex component and a lot of other less advanced ones. In addition, we are developing 6 different UI Kits - MDB Standard, MDB React, MDB Vue, MDB Angular, TE Standard and TE React
We are aware that DataTable.net will be more advanced than our Datatable. Just like CKEditor will be more advanced than our WYSIWYG. But as I mentioned, they focus on one solution and can spend 100% of their time developing it.
However, due to the great interest in more advanced tables, we decided to create such a solution. We are currently working on tables supporting server-side processing, more advanced sorting and searching, the ability to dynamically resize columns or change the order in which columns are displayed, and many other features
Riva pro premium priority commented 6 months ago
I understand MDB is a UI kit and that you don't primarily focus on datatables, but it is a key differentiator that Bootstrap doesn't support. It was the primary reason we chose MDB. Building datatables from scratch is a relatively heavy lift and worth the annual subscription fee if your datatables are on par with other libraries (especially free ones).
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- User: Pro
- Premium support: Yes
- Technology: MDB React
- MDB Version: MDB5 6.2.0
- Device: Any
- Browser: Any
- OS: Any
- Provided sample code: No
- Provided link: Yes
mlazaru staff commented a year ago
We are currently working on a more complex version of the datatable component, and we will also include this feature.
LyncoDev pro premium commented a year ago
Can you elaborate on the more complex version? My impression as a paying user looking for what I felt was basic functionality has been pretty disappointing and that seems to ring true through your support community and stackoverflow. I think as a community, we probably have far more requests for what we feel is a basic level of functional datatable than what are on this support system.
These are the basic features I'm personally looking for *Separating data from render (so I can format the output without destroying the data) *Sorting by data, not rendered values *Row, Column and Cell formatting based on data *Column filters *Editable fields (ex: add any type of MDB Form component)
As a paid product, you are competing with DataTables.net which has far more functionality and no cost. I honestly hope you are setting the bar somewhere near that.