|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Reoccuring events don't sort properly with non-Reoccuring
When an event is set to reoccure, it doesn't sort right with other events. Observe:
http://calendar.codewalkers.com/cal...th=10&year=2004 october 18th. At 6 am there is an event which occurs every monday and was started the week before. However on the 18th, this reoccuring event which happens at 6AM is above an event that starts at 2AM. Does anybody know how to fix this? thanks. |
|
#2
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
I noticed that problem also. It's because it's sorting by the date and time, not just the time. That's why the recurring event shows up first. It has a start date before the other events for that day. But sorry, I don't know how to fix it.
|
|
#3
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
can you point me to which line or at least in which file this happens. I probably can hack something together with enough time.
|
|
#4
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
I think it’s in ltwdisplaymonth.php where it does the select. It has an ORDER BY event_date, day_event DESC, start_time. The event_date is the first date of the recurring event. When I saw that I realized it probably wasn’t an easy fix. I’m not a php expert so I didn’t try. If you do fix it let us know.
|
|
#5
|
|||||
|
|||||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
yeah! I think I figured it out...
line 137 in ltwdisplaymonth.php I'M NOT SURE IF THIS IS A END ALL FIX ALL SOLUTION. DON'T HOLD ME TO THIS. It looks like this fixes the problem, but there might be other side-effects that I can't see. If anybody sees any errors in what I've done, please post back!!!! The original line is commented out. php Code:
[edit]the php format code auto ads a ?> !!!! don't put that in the file!! Like I said, it SEEMS to work, but I'm not sure. Any feedback would be much appreciated. -ben |
|
#6
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
I tried it and it appears to work. No adverse affects as far as I can tell. Good work.
You should also make the same change in ltwdisplaylist.php. That is the list display. |
|
#7
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
good deal, I hope it helps some other people out there. Also, it appears that this calendar has like sorta died. Is there any way (if my change is legit) could be added back into the source? Cool.
-ben |
|
#8
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
That last post was me, just forgot to login ;)
|
|
#9
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
The calendar hasn't died, it's just been a matter of having the time to devote to it.
I'm planning a new release that will use adodb to support both mysql & postgresql, but I simply haven't had the time to do it. In the process, I'd like to fix all the bugs, add more recurring event types (monthly, day of month, yearly) and simplify the date/time inputs (by using strtotime), and a few other things. I also want to write a query class so you can easily look events up without any SQL statements in your code. Then you could easily write custom displays using the underlying core code. For example, on my Troop's web page, I'd like to be able to put the description of the next meeting agenda on the "home page" for people to see without having to go to the calendar page. A query class would make that easy. |
|
#10
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
Ya, a class is the way to go. I use the calendar a lot, so I'll be sure to post any bugs. Wan't 'em here or in another thread?
-ben |
|
#11
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
bug: table rows without events in them collapse. Also, are you sure you want to use adodb?? Why not just stick with mysql? Codewalkers is all about php and sql. A class would be so easy to make, however making adodb seems harder (and plus it would drive me insane)
-ben |
|
#12
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
I'm not talking anything Microsoft here, I'm talking http://adodb.sourceforge.net/, a php library that would allow the calendar to be used with PostgreSQL as well as MySQL. Something people have asked for.
|
|
#13
|
|||
|
|||
|
RE: Reoccuring events don't sort properly with non-Reoccuring
F ms dude. I know your not talking ms. I'm just saying that adodb isn't very common, and that straight mySql would be better. I mean, if you want it to be easy to edit an all. Just my input ;)
-ben |
![]() |
| Viewing: Codewalkers Forums > Projects > ltwCalendar > Reoccuring events don't sort properly with non-Reoccuring |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|