The schedule should allow for the possibility of the rooms in use on one day of the event to differ from the rooms in use on another day.

Comments

coltrane’s picture

While discussing in IRC today we thought of two options:

1. For a given day, do not show the rooms which have no sessions scheduled in to them
2. Use nodequeue to make a room queue per day, the schedule page then becomes multiple View displays

ezra-g’s picture

I think that #2 adds complexity and configuration without clear benefit.

With #1 and a single queue to sort all rooms as in #1024938: Configurable room order on schedule, we can have one schedule for BOF and one for regular sessions simply by filtering the schedule view based on the session (or BOF) content type.

coltrane’s picture

The goal is the same, neither option provides benefits while not providing complications. Option #1 means more custom code to maintain in the .module file while #2 has more configuration (and processing overhead) I think.

ezra-g’s picture

In my mind #1 can be close to doing an if (empty check for whether there are sessions scheduled in a room on the day being processed, and an unset on the room if there are no sessions schedule.
If this is integrated into cod_session then it's community rather than custom code.

With #2 we'd stil have to write logic to associate queues with views/days, which seems likely to be more complex logic and code (since the #of days is dynamic, depending on the configured timeslots) as well as config.

coltrane’s picture

Great points Ezra, I concede to #1.

coltrane’s picture

Status: Active » Needs review
StatusFileSize
new6.55 KB

Have to do a bit of data organization and another loop. template_preprocess_cod_session_calendar() is looking mighty ugly, but this works. Perhaps we can clean it up after the feature set is complete, before a 1.0.

To test, create an event with time slots spanning two days and three rooms. Put a session in both rooms in a slot on the first day and a session in a different room in a slot on the second day and see the two different rooms on the schedule, and no other rooms.

coltrane’s picture

#6 had something odd with a query spacing.

coltrane’s picture

There was an error caused if all the rooms were empty for a certain time slot. Need to check if array element is set.

JHarahush’s picture

Hi, I just tried to apply the most recent patch (from comment #8) and I'm fairly certain I've done it correctly (I tried a few times, just to make sure), but I'm getting an error that says something along the lines of "expecting an array, but received null" on for the following lines in the schedule template file:

if (!in_array($room_key, $empty_rooms[$day_key])):

and

if (!in_array($room_key, $empty_rooms[$day_key])):

Despite the fact that I get this error when looking at the schedule, the patch works -- meaning, the unused rooms for the first two days of my conference do not show up, which is what I want.

I don't have my code in front of me right now, but if you have any hints or things I should look for, let me know! I assume I only needed to make the changes in comment #8, right? Or do I need to make the changes in 6, then 7, and then 8? I'm not good at debugging PHP.. yet.

Thanks so much -- and my apologies if this isn't the correct place to post this question.

ezra-g’s picture

@JHarahush - Can you paste a screenshot of your schedule to help us reproduce?

coltrane’s picture

This feature is handled by the most recent patches in #1034482: BoF Scheduling tool

coltrane’s picture

Status: Needs review » Fixed

Reopen if needed but documentation is starting at http://drupal.org/node/1208088

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.