uasoft-indonesia / badaso

Laravel Vue headless CMS / admin panel / dashboard / builder / API CRUD generator, anything !
https://badaso.uatech.co.id
MIT License
1.21k stars 224 forks source link

Client side sort does not work with null values #1073

Closed Dri372 closed 1 month ago

Dri372 commented 4 months ago

In a crud, if a column has new values, the sorting of this column does not work.

Solution in : vendor/badaso/core/src/resources/js/components/BadasoTable.vue / sortItems

        //if ( a[currentSortKey] < b[currentSortKey] ) {
        if ( (a[currentSortKey] ? a[currentSortKey] : '') < (b[currentSortKey] ? b[currentSortKey] : '') ) {

same for next if

Badaso version ; 2.9.11

stale[bot] commented 2 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.