Home › Forums › Calendar Products › Events Calendar PRO › Can you modify when events are relegated to 'previous' status?
- This topic has 6 replies, 2 voices, and was last updated 12 years ago by
Barry.
-
AuthorPosts
-
December 16, 2013 at 12:40 pm #81945
jimmulvaney
ParticipantMy client would like to have all of his (for example) December events listed (we only use list view) during the month of ‘December’ regardless of whether or not they have already passed. So basically, he does not want it listed as a previous event until the month is over. Any help would be appreciated and I am accustomed to PHP and other code languages (except Javascript or similar), just need to know where to look and what needs to be done. Thanks,
December 17, 2013 at 7:27 am #82067Barry
MemberHi jimmulvaney.
There are a few ways you might tackle this.
We already have a month view that sounds like it meets your goals, insofar as it only shows events from a single month at any one time. There is no reason you couldn’t customize the month view templates so that the events are ordered and rendered as a list, rather than a grid view.
You could even keep the existing month view structure in place and add code to listen out for some indication – such as an extra URL query parameter – that the month view should be presented list-style and load a new set of templates only under those conditions.
Another alternative would involve filtering and modifying the query used to retrieve the event data for the existing list view, or else creating a new custom view of your own that works exactly as you anticipate.
Last but not least, you could always fall back on a ‘cheap and cheerful’ solution by catching any requests that you need to alter (such as a request to the main events page) and redirecting to a specially crafted URL like this example from our demo site – or just linking customers to it right off the bat from your menu:
http://wpshindig.com/events/upcoming/?action=tribe_list&tribe_paged=1&tribe-bar-date=2013-12-01
The query parameter at the end means all events starting December 1st or later, including those that have passed, would be shown in list view. The downsides of course would be that, depending on your number of events to show per page setting it may either not include all events in December or may additionally include events in January.
This sort of approach is consequently a bit ‘hacky’, in a sense, but you could workaround some of those limitations by being creative – setting a high number of events to show per page then customize the list view templates and ignore events that don’t meet your criteria (that aren’t in the current month, let’s say). Ultimately that’s not the cleanest way to do things – but it might work for you.
I hope that gives you some ideas to explore, we’d really need to leave it to you to figure out what works best for you.
Good luck!
January 2, 2014 at 9:13 am #85599jimmulvaney
ParticipantThanks for that but it is much more complicated than I was anticipating. I need a quicker solution than that as I really don’t have the time to work on it in that fashion. Basically, I was just wondering if there was a variable or parameter I could change in the code that would allow me to dictate ‘when’ an event gets labeled as “previous”? Also, I would still need specific code examples or the file names I can find the code in.
January 8, 2014 at 1:49 pm #88801Barry
MemberApologies for the delay – we just migrated to a new set of support tools and unfortunately that seems to have resulted in some threads not being flagged up as in need of a reply.
I was just wondering if there was a variable or parameter I could change in the code that would allow me to dictate ‘when’ an event gets labeled as “previous”?
The thing is – at least at database level – we don’t append a flag or anything like that to mark events as passed.
That’s simply assessed query-by-query on the basis of the event date fields. I’m sorry to hear none of those options I outlined are going to be feasible for you, but I think really that indicates, for this specific issue – which is really a custom development task – you need a higher level of support that we can realistically provide for you here on the support forum.
We can certainly provide you with a list of suitable freelancers/independent devs if you need someone to work through this with you?
January 9, 2014 at 9:03 pm #89871Barry
MemberHi jimmulvaney: just checking in here – does that last post provide any further clarity / would you like a list of devs who can assist further?
January 9, 2014 at 9:45 pm #89903jimmulvaney
ParticipantSorry, just been real busy. We decided to go another route, thank you.
April 17, 2014 at 5:51 am #134751Barry
MemberThis thread’s not seen much activity recently so I’ll go ahead and close it. Of course if you still need help with this or any other issue please don’t hesitate to create a new thread (or threads) and one of the team will be only too happy to help. Thanks!
-
AuthorPosts
- The topic ‘Can you modify when events are relegated to 'previous' status?’ is closed to new replies.
