bethlakshmi / GBE2

Great Burlesque Expo (www.burlesque-expo.com) system in django
2 stars 2 forks source link

Why is it worthwhile to have a start time on both Event and ResourceAllocation #147

Closed bethlakshmi closed 10 years ago

bethlakshmi commented 10 years ago

So... right now the ResourceAllocation and Event are both Schedulable.

That means they both have a start_time, although only the Event can meet the rest of the implied contract, since ResourceAllocations don't have durations, so the Schedulable.duration and Schedulable.end_time can't be provided.

I can live with it... but I ended up confusing the heck out of myself in the following way:

1 - Take a gbe.Event (which has an EventItem for a parent) and make a scheduler.Event for it. 2 - Scheduler.Event is Schedulable, and so wants to have a start_time - cool, I gave it a start time (let's say 1/1/2014 at 12:00 EST) 3 - Set up some gbe.Rooms - they are LocationItems 4 - Give the LocationItems 1 Location each. 5 - Assign via ResourceAllocation the Locations to the scheduler.Event, 1 ResourceAllocation for each assignment. 6 - * HERE IS THE CONFUSION * - because ResourceAllocation is also Schedulable, I now have the option for two start_times -- the event start_time is set for the scheuduler.Event but the allocation of location to event also needs a start time.

By implication - a resource that is assigned to an event is scheduled for the length of the event.

I think we muddy the waters with having the potential for the allocation to have a different start time than the event... I'm trying to figure out what value we get from this that makes it worth the potential display confusion.

I assumed for displaying schedule details that for public display purposes:

And then I assumed the resourceallocation start_time just didn't matter for display purposes.

jonkiparsky commented 10 years ago

Good point. I made resource allocations schedulable when I was assuming that start_time would live on the event and schedulable would simply tell us that this thing can report a start time (ie, as a property) Then you have resource allocation getting its start time and duration from its event, and that lets us show resource availability schedules. (this was the point of schedulable)

Should we go back to that approach? Is there any reason why the start_time data should be stored under schedulable and not under scheduler.event?

On Mon, Oct 20, 2014 at 9:48 AM, bethlakshmi notifications@github.com wrote:

So... right now the ResourceAllocation and Event are both Schedulable.

That means they both have a start_time, although only the Event can meet the rest of the implied contract, since ResourceAllocations don't have durations, so the Schedulable.duration and Schedulable.end_time can't be provided.

I can live with it... but I ended up confusing the heck out of myself in the following way:

1 - Take a gbe.Event (which has an EventItem for a parent) and make a scheduler.Event for it. 2 - Scheduler.Event is Schedulable, and so wants to have a start_time - cool, I gave it a start time (let's say 1/1/2014 at 12:00 EST) 3 - Set up some gbe.Rooms - they are LocationItems 4 - Give the LocationItems 1 Location each. 5 - Assign via ResourceAllocation the Locations to the scheduler.Event, 1 ResourceAllocation for each assignment. 6 - * HERE IS THE CONFUSION * - because ResourceAllocation is also Schedulable, I now have the option for two start_times -- the event start_time is set for the scheuduler.Event but the allocation of location to event also needs a start time.

By implication - a resource that is assigned to an event is scheduled for the length of the event.

I think we muddy the waters with having the potential for the allocation to have a different start time than the event... I'm trying to figure out what value we get from this that makes it worth the potential display confusion.

I assumed for displaying schedule details that for public display purposes:

  • the event item is my "what piece of Expo content are people centered on?"
  • for each event item, display all cases of scheduler.Event - so that you can see every time something is offered, in case it's offered multiple times. - \ the time of the scheduler.Event is the time displayed.**
  • for each scheduler.Event, the locations that are allocated should be shown with the scheduled time.

And then I assumed the resourceallocation start_time just didn't matter for display purposes.

— Reply to this email directly or view it on GitHub https://github.com/bethlakshmi/GBE2/issues/147.

bethlakshmi commented 10 years ago

I think moving start_time and the other properties of Schedulable to scheduler.event makes perfect sense. Then we can kill Schedulable and have one less abstraction.

I can't think of a time when a resourceAllocation needs to report a start time when it doesn't also need all the other stuff associated with the event. For example, I can see the value of a room report where we specify a room and then map all the events in that room and their start times - but at that point, you really want the pile of resource allocations that are for the the Locations associated with this LocationItem, and then you'll ask each resource allocation for it's event and get the pile of useful event data (title, start_time, duration). Same idea for person (what's my schedule?) or even equipment (where does this thing go next?).

Let's pull schedulable and move it's functionality to scheduler.event.

jonkiparsky commented 10 years ago

No, we still need resource allocations to be Schedulable if we want to be able to show schedules of rooms and persons. We move the data field to s.Event, but keep the "interface".

On Mon, Oct 20, 2014 at 9:05 PM, bethlakshmi notifications@github.com wrote:

I think moving start_time and the other properties of Schedulable to scheduler.event makes perfect sense. Then we can kill Schedulable and have one less abstraction.

I can't think of a time when a resourceAllocation needs to report a start time when it doesn't also need all the other stuff associated with the event. For example, I can see the value of a room report where we specify a room and then map all the events in that room and their start times - but at that point, you really want the pile of resource allocations that are for the the Locations associated with this LocationItem, and then you'll ask each resource allocation for it's event and get the pile of useful event data (title, start_time, duration). Same idea for person (what's my schedule?) or even equipment (where does this thing go next?).

Let's pull schedulable and move it's functionality to scheduler.event.

— Reply to this email directly or view it on GitHub https://github.com/bethlakshmi/GBE2/issues/147#issuecomment-59864835.