Support

Home Forums Event Espresso Premium Sorting Inconsistencies

Sorting Inconsistencies

Posted: November 7, 2023 at 11:30 am


socialsparkmedia

November 7, 2023 at 11:30 am

When I view registrations I want to sort them by the event date, the default sort appears to be the TXN date. When I click on the arrows next to the Event Date heading to sort them by that date, I don’t see any dates for December, even though I know from the default sort that there should be at least 3 December dates. I want to see the Event dates in chronological order on this page.

Screenshots:
Default sort order: https://app.screencast.com/DDxrftNnYYY7E
Sort by Event Date: https://app.screencast.com/W38GHxofbl7Mu


Rio

  • Support Staff

November 7, 2023 at 7:59 pm

Did try to recreat the issue from our end, but everything seems fine. https://monosnap.com/file/5LVlwsAVocJXl6lZEwHLeTtSBvmJni

Can you tell me more information about that page? how about you shoot a video using loom. There could be some information we can see there that might be helpful in our troubleshooting.

https://www.loom.com/

thanks


socialsparkmedia

November 8, 2023 at 9:59 am

This reply has been marked as private.


Rio

  • Support Staff

November 10, 2023 at 5:00 pm

I think it works fine. the first time you click it sort by DESC, it sorted. The second time you click it, it brings back to default sorting.

Can you tell us what you expect to happen when you click the button on the 2nd time?

thanks


socialsparkmedia

November 13, 2023 at 11:41 am

Hey Rio,
As I mentioned in my initial question, I don’t see any dates for December when I click to sort the second time, even though I know from the default sort that there should be at least 3 December dates. I want to see the Event dates starting with January 25 (if that’s the furthest out event that someone is registered for), then December’s dates, etc., in chronological order, but instead, I’m seeing November, January, November, November, etc. and nothing from December. It’s not in any kind of order for the Event Date column.


Tony

  • Support Staff

November 13, 2023 at 5:06 pm

Hi Fran,

That’s not a simple sort although it may seem it.

The reason your not seeing the December registration in your screenshots is the query orders_by like this:

ORDER BY Event___Datetime.DTT_EVT_start desc,Registration.REG_ID desc

We add the orderby REG_ID because the results returned from the Database query can be a little… random without it.

The code for this actually has a comment referring to it:


// because there are many registrations with the same date, define
// a secondary way to order them, otherwise MySQL seems to be a bit random
if (empty($orderby['REG_ID'])) {
    $orderby['REG_ID'] = $order;
}

But, those where conditions are filtered so you can try using a snippet on your site to see if it helps:

https://gist.github.com/Pebblo/04448f9f82f55dc90d055944893da5e1

Try adding that snippet to your xee-customizations plugin.


socialsparkmedia

November 14, 2023 at 9:17 am

Hey Tony,
Thanks for this additional information. I added the snippet to my snippet app, rather than the plugin, but I think that’s fine. It is sorting differently, but still not right. I will add a screenshot in a private message after this one.

What’s happening now is that the second time I click the arrow to sort it starts with January of 2023 and goes up, only not always in the correct order. Also, I see a lot of registrations that are showing in gray, to indicate canceled, and also purple, to indicate wait list. This can’t be right. The payments are showing as green for most of them.


socialsparkmedia

November 14, 2023 at 9:19 am

This reply has been marked as private.


Tony

  • Support Staff

November 14, 2023 at 3:24 pm

Yeah unfortunately I don’t think that’s something we can fix without a deep dive into the registration data, matching the setup and seeing exactly whats is happening with the query.

If you view registrations for a specific datetime does that display correctly?


socialsparkmedia

November 15, 2023 at 1:14 pm

How would I view registrations for a specific datetime? When I look at the registrations page and filter by date, that is only for Txn date so I can’t see into the future.


socialsparkmedia

November 15, 2023 at 1:17 pm

This reply has been marked as private.

The support post ‘Sorting Inconsistencies’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso