• Resolved nishantoswal

    (@nishantoswal)


    We have installed the tablepress extension sorting plugin but nothing seems to be working. Reffer to the canada recommendation table, we are trying to use sort table by date but its not working.

    The sorting stops as soon as we add the following comand “columnDefs”: [ { “type”: “date-eu”, “targets”: [ 2 ] } ]

    Can you please assist us. We want customers to sort by dates too in dd-mm-yyyy but its sorting like numbers

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author TobiasBg

    (@tobiasbg)

    Hi!

    Thanks for your post and sorry for the trouble!

    At this time, the date format dd mmm yyyy that you are using is not supported natively (it will be in the upcoming TablePress 3, currently scheduled for early November).

    Therefore, I recommend using an approach like https://www.ads-software.com/support/topic/date-order-6/ where you add extra (hidden) columns with the date in mm/dd/yyyy format, used only for the sorting.

    Regards,
    Tobias

    Thread Starter nishantoswal

    (@nishantoswal)

    Ok so i changed the date to mm/dd/yyyy But when we click on Buying date to sort, its giving random results. Is there a way we can get it correct. When anyone click in there to sort they can sort with nearest date to farthest and viceversa

    Thread Starter nishantoswal

    (@nishantoswal)

    Hey it worked added a new coloum with s.no and then used this

    “columnDefs”: [ { “orderData”: [ 2 ], “targets”: 3, visible: true }, {targets: 2, visible: false}]

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    perfect! In the visible columns, you could now also go back to a format like 4 Jul 2024 if you prefer that format.

    Best wishes,
    Tobias

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.