Issue 813: Mark past dates and current time
Status:  Duplicate
Merged:  issue 143
Owner: ----
Closed:  Feb 2011
Reported by hiemstra...@gmail.com, Feb 1, 2011
Hi,

First of all, I love your script! But I miss a few things, could you consider implementing these natively? 


- Date format in day/week view in left column are always in AM/PM even if I set timeFormat to 24hour format

- It would be really nice if optionally you can make the day's in the past grayed-out in all views. I hard-coded this in your script for now, but a native solution would be cool!

- A red-line marker for the current time in day and week view, See google calendar for a preview. Would be a nice feature! 

I hope you can consider this, I would even pay for it! or make a donation ;)
Feb 1, 2011
#1 hiemstra...@gmail.com
Oops sorry, Never mind the first item, its actually in here :D axisFormat, thnx man!
Feb 2, 2011
Project Member #2 althaus.it
You already found axisFormat. Adam perhaps should add a crosslink to the documentation. ;)

For current time indicator see https://code.google.com/p/fullcalendar/issues/detail?id=143
Feb 2, 2011
#3 hiemstra...@gmail.com
Hi,

Yes, I found that entry before but the reply from the author is "this is currently not possible". And it will be in an upcoming release, but since the entry is dated nov 2009 and its not here yet thats why I reposted :)


Feb 2, 2011
#4 hiemstra...@gmail.com
Ok sorry for my impatience but I could wait had to push a release today :)

I added the past-dates and past-time myself, hardcoded in the code, its not a beauty contest winner but it works.

Going to work on the current time "line" now, hope I figure it out! :)

For anyone waiting for this feature who cant wait can use my customized code see attached file.
Based on v1.4.8, but if you search for the string "Edit by" and paste all the pieces in the latest it should work fine.

2 classes are added to all views: fc-pastdate and fc-futuredate

fullcalendar.js
112 KB   View   Download
Feb 2, 2011
#5 hiemstra...@gmail.com
Lol, the red line was simpler then I thought, just add 

((c_sss == 0) ? ' fc-pastdate-line ' : '') + 

at line 2155 (In my file attached above)
Feb 2, 2011
#6 hiemstra...@gmail.com
Check it out!

Screen shot 2011-02-02 at 8.05.26 PM.png
29.4 KB   View   Download
Screen shot 2011-02-02 at 8.05.37 PM.png
24.6 KB   View   Download
Screen shot 2011-02-02 at 8.06.32 PM.png
32.1 KB   View   Download
Feb 3, 2011
#7 hiemstra...@gmail.com
Hmm the calendar does not re-render so it doesnt set the columns for the next week, or next day for that matter to in-future... 

$('#calendar').fullCalendar('render');

does not help either :( can you think of something?
Feb 13, 2011
Project Member #8 adamrs...@gmail.com
thanks hiemstra...@gmail.com

thanks for starting to implement this. unfortunately, it is not a good use of my time to help other people debug their new code. hope you understand. when i get to formally implementing the feature, i will look at your code.

i am going to merge this with  issue 143 . even though it is old, people are still "watching" the feature...
Status: Duplicate
Mergedinto: 143
Feb 23, 2011
#9 hiemstra...@gmail.com
I understand, ofcourse. No problem. But can you give me advice on how to re-render the structure so the classes get removed, or re-added when clicking on the next/prev date? For instance, when the calendar gets rendered it puts in the classes for the structure (date-inpast/infuture) but when you click next day/month/week it does not re-render the structure, therefore does not remove the date-inpast/future classes. How can I call this action? or is it possible even in the current source. I would really like your advice and ill make sure I make a generous donation to support development of this great script!
Apr 7, 2011
#10 marcovra...@gmail.com
And now on version 1.5 the code is really diferent ? can any one help with the new patch ? 
the function renderAgenda is completely diferent

hiemstra can you help ?

thanks
Apr 12, 2011
#11 hiemstra...@gmail.com
Too bad adam is not responding, I really need this in my product. I will dive into it sometime this coming weeks and make a patch for it. 
Apr 13, 2011
#12 hiemstra...@gmail.com
I've made a start on this feature, you can download the source from my fork at github:
https://github.com/mdahiemstra/fullcalendar

It build on the latest version, and currently supports:
- current time indicator in day/week view
- past dates are grayed-out (fc-past-date class) in all views

There is one known issue, I already sent a message to adam for help but until then the issue stands:
- When in day view, clicking the next day button does not update the structure, so the fc-past-date class does not get removed

Apr 15, 2011
Project Member #13 althaus.it
(No comment was entered for this change.)
Summary: Mark past dates and current time
Aug 10, 2011
#14 and...@gmail.com
How did you go about doing the red line?

Also, why are you changing the code itself, wouldn't it be better to do your work outside of fullcalendar and integrate it with callbacks from fullcalendar, so when the core is updated, it won't kill your work.
Aug 16, 2011
#15 orion...@gmail.com
I would (also) like the possibility to choose a box red box around the current day in stead of just the bold-date-number. 
Any calender should have this option ;)

Maybe it could be something you could choose in the lab section. It's at least as relevant as the other things in there ;)
Apr 27, 2012
#16 willems....@gmail.com
And why not define the red box with css?