Sorting in Calendar Pro

Support for our integrated Contact Manager, Calendar, and Project Tracker.
Posts: 41
Joined: Mon Nov 11, 2013 11:12 am
PostPosted: Thu Jul 10, 2014 5:20 am
Is there a way to customize the sort of events in Calendar Pro? I found a thread pointing to a specific sort script, but I'm not seeing that in the latest version.

I would like to sort by start time, but put events that don't have a start time at the end of the sort order.
SeedCode Staff
SeedCode Staff
Posts: 475
Joined: Wed Jan 02, 2013 11:47 am
PostPosted: Thu Jul 10, 2014 5:30 am
Hi Jason. We consider events with no start time "all-day events", and they appear in their own section at the top of the Day, Week and Schedule views. Are you just saying you'd rather have that all-day section at the bottom of those views instead of at the top? -Jeff
Posts: 41
Joined: Mon Nov 11, 2013 11:12 am
PostPosted: Thu Jul 10, 2014 9:52 am
Hi Jeff,

The "all day events" are fine as they are on the day and week views, but on the month view they are listed first. This particular client is using them to represent non-events (like a customer pickup). There may be 4 or 5 of those scheduled for a day in addition to 3 or 4 appointments. If I could sort them after the appointments that have a start time, then on the month view, I would see the appointments rather than the all day events. Does this make more sense?

Thanks,
Jason
SeedCode Staff
SeedCode Staff
Posts: 475
Joined: Wed Jan 02, 2013 11:47 am
PostPosted: Thu Jul 10, 2014 10:19 am
Yeah, that makes sense. You should be able to do that by editing the "ORDER BY" clause in the SQL query. That clause gets added in the "Add Order By" section toward the end of the "Cast Events as Variables - Build Query" script. Right now we're just sorting by the first field in the SELECT clause, which is the starting timestamp field ("ORDER BY 1"). You might have to add a flag field to distinguish "all-day" events from events with start times, then sort by that first ("ORDER BY all_day_flag DESC, 1"). You might also want to add some logic so that only happens on Month View. HTH... Jeff
Posts: 41
Joined: Mon Nov 11, 2013 11:12 am
PostPosted: Thu Jul 10, 2014 11:06 am
Makes sense. Thanks for pointing out where that is located.

Jason

Return to SeedCode Calendar

Who is online

Users browsing this forum: No registered users and 2 guests

cron
(855) SEEDCODE
support@seedcode.com
Follow us: