Skip Navigation

[Resolved] Filter a view by multiple date custom field

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 3 replies, has 2 voices.

Last updated by javierP-9 2 years ago.

Assisted by: Waqar.

Author
Posts
#2507319

Hi again! Still messing with my travel agency site and the custom post type Tour. I had a RFG with departure dates and a check for confirmed departure dates for each. After all the problems I had handling with this Repeatable field group, I decided to discard it and use two separate custom fields, departure dates and confirmed departure dates, thinking it's going to be easier to handle dates with standar custom fields instead of RFG.
I'm trying to display in a view only tours with a confirmed departure date. This field can have multiple values. To make this view I am trying to use a query filter in the view, but all the filters I tried using DATE didn't work. I only need to make a query filter displaying tours with a confirmed departure date saved.

The front-end url displaying this is hidden link

Thanks in advance

#2507957

Hi,

Thank you for contacting us and I'd be happy to assist.

To troubleshoot and suggest the best way to achieve this, I'll need to see how these fields and the view are set up in the admin area.

Can you please share temporary admin login details, in reply to this message?

Note: Your next reply will be private and making a complete backup copy is recommended before sharing the access details.

regards,
Waqar

#2510391

Thank you for sharing these details.

I noticed that the page in question was using the view named "Tours con salidas de grupo".

WordPress query ignores all results where the custom field that is set for filtering is not set. So in this view's query filter settings, I updated the query for the "fecha de salida grupo confirmada" field so that 'it is a number different from (not equal to) empty constant value'.
( screenshot: hidden link )

This seems to be working and the view is showing only two "Tour" posts, where a value for this custom field is set.

I hope this helps and please let me know if you need any further assistance with this.

#2511757

My issue is resolved now. Thank you!