Closed (duplicate)
Project:
Event
Version:
4.7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
12 May 2006 at 18:07 UTC
Updated:
20 Mar 2007 at 11:53 UTC
Rather than repeating the event info for each day that a multiple day event spans (such as a conference), it would be great if there were a single description per week (in the week or month view) and a narrow horizontal bar that spanned the days. This would more accurately present the event and take up less real estate.
Thanks.
Comments
Comment #1
BachusII commentedThere is a bug on lines 1007, 1012 & 1016 of
// $Id: event.module,v 1.183.2.6 2006/05/22 13:54:07 killes Exp $
On those lines an object (
$nid) is placed in an array. (On the preceding line anevent_stateis set.)As is, each and every time one of these is set it's the exact same instance of the exact same object. On multi-day events what you expect is start-ongoing-ongoing-end. What you get is end-end-end-end
The fix is to clone the object each time.
Now, for single bars. in
// $Id: event.theme,v 1.26.2.3 2006/05/22 13:35:07 killes Exp $
On line 157, add the
event_stateto the class. (Prefix of suffix it with something (anything) otherwise it will clash with another class.)The rest is a CSS exercise. The following gets a "worksforme";
(IE may choke on the !important rules.)
Comment #2
BachusII commented/ $Id: event.theme,v 1.26.2.3 2006/05/22 13:35:07 killes Exp $
Line 107
And you can remove the
.event.monthviewclasses from the CSS selectors.Comment #3
kloomis commentedThanks. That looks great. I'm looking forward to implementing it.
Ken
Comment #4
kloomis commentedThe code above is great! Just what I was looking for.
A couple of notes:
The clone fix is required for PHP5 but not PHP4 and below.
See: http://www.hat.net/geeky/php_tricks_-_php_5_clone_in_php4
So, if you're running PHP4 you can leave it alone, it works fine, or use the suggested code at PHP tricks for portability.
Also, just my preference, in the css I removed the title in the event_end from the visiblity:hidden and I removed it from the width: 1em so that the title shows up at the beginning of the event and at the end. I also added a height:2em attribute to monthview.event.ongoing to create a narrow bar for the ongoing sections.
Thanks, again.
Comment #5
BachusII commentedThis issue was raised again yesterday, see http://drupal.org/node/85972
I thought it prudent to adapt the title of this bug.
The problem remains, in CVS HEAD too.
Comment #6
killes@www.drop.org commentedwe have a drupal_clone function that works with php 4 and 5. This should be used.
Comment #7
BachusII commentedWhich would be http://api.drupal.org/api/HEAD/function/drupal_clone
If event.module and event.theme are patched as killes and I suggested, we can turn this issue back to a (closed) feature request.
Comment #8
killes@www.drop.org commentedhttp://drupal.org/node/118760