Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Events: Search filters - remove countries without events #1173

Open
pkevan opened this issue Dec 11, 2023 · 3 comments
Open

Events: Search filters - remove countries without events #1173

pkevan opened this issue Dec 11, 2023 · 3 comments

Comments

@pkevan
Copy link
Contributor

pkevan commented Dec 11, 2023

Having a list of every country in the world is unnecessary as a search filter - it would be more appropriate to list the countries where events are going to take place, than having a huge list to filter where they might not return any results.

@pkevan
Copy link
Contributor Author

pkevan commented Dec 11, 2023

Screenshot 2023-12-11 at 08 57 19

Example: all countries which appear in the list currently have no events.

@iandunn iandunn added this to the Events: Promotion milestone Dec 11, 2023
@iandunn
Copy link
Member

iandunn commented Dec 11, 2023

Right now it's using wcorg_get_countries(). I think we'd have to change it to query wporg_events, and get the distinct country codes where there's at least 1 upcoming event. Then we'd need to JOIN to one of the Geonames tables to get the country name.

We'd also need to switch that to query past events when looking at the Past Events template.

That might introduce some problems w/ country names that CLDR solves, but that's probably a smaller issue that what's being fixed.

I wonder if the need for this will be removed once we add searching? That should make it easy for folks to find what they're looking for, and at that point the need for this seems minimal to me. What do you think?

@pkevan
Copy link
Contributor Author

pkevan commented Dec 12, 2023

Yeah, I looked into it a bit yesterday, and found it was quite complicated - I was hoping that the stat 108 countries on the homepage was a cached query somewhere that would help this, but turns out it's manual. The other option I thought about was through: https://central.wordcamp.org/reports/meetup-groups-report/?report-year=2023&period=all&action=Show+results which returns countries.

It could well be solved with searching, since I wonder who really uses filters these days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 🛑 Pending discussion
Development

No branches or pull requests

3 participants