Closed (fixed)
Project:
FullCalendar
Version:
7.x-2.x-dev
Component:
Code
Priority:
Major
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
21 Nov 2011 at 18:21 UTC
Updated:
4 Jan 2014 at 01:39 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
tim.plunkett#1348604: Rework to use CTools CSS plugin to store generated CSS as a file is how I think we should fix this.
Comment #2
aspilicious commentedWell I don't agree completly on this. The problem is that we don't call the color code when switching months. We (or I) have to figure out first WHY we the classnames are added but the color code isn't called... They live in the same function thats why it confuses me.
Comment #3
tim.plunkettWow is the ctools css stuff easy.
Okay, so pretend that fullcalendar_colors_create_css_file() is a colors.module function. I just put it in fullcalendar_colors so it could be patched against fullcalendar.
The changes to fullcalendar_colors_set_color() are not ideal. I need to think about that more. It needs to be something closer to the changes in fullcalendar_colors_admin_settings_submit().
There is likely a lot more in fullcalendar_colors.module that can be ripped out, but this is a start.
Comment #4
aspilicious commentedWorks after clearing caches in some cases.
If there are no events on the landing page, the calendar doesn't load.
I'm not sur this is caused by this patch or those other changes you pulled in yesterday.
Comment #5
tim.plunkettYeah I messed that up last night. Fixed now.
I also realized the empty handler is completely unused now....
Comment #6
tim.plunkettOkay so a couple issues:
aspilicious suggested we just rebuild the css on every submit, but that's not exactly ideal either.
Comment #7
tim.plunkettComment #8
tim.plunkettHere's a first stab. Still haven't addressed the first two points of #6, and I might refactor more.
Comment #9
tim.plunkettUgh 0 bytes fail
Comment #10
tim.plunkettAt the end of this, fullcalendar_colors should be about four functions:
fullcalendar_colors_colors_build_selector()to dictate the selectorfullcalendar_colors_preprocess_fullcalendar()to add the filefullcalendar_colors_create_css_file()or something to generate the filefullcalendar_colors_fullcalendar_classes()to add the classesComment #11
tim.plunkettThe default color stuff is still not done, but the rest looks pretty good to me.
Upgrade path is still untouched.
Comment #12
aspilicious commentedI'm not sure this broke my use case again. Can you do the following:
1) Add custom colors css
2) But don't add it to the classes array
Comment #13
tim.plunkettWe could add a flag per plugin to exclude when adding classes not colors. Would that work? Your code NEVER gets added as classes, right?
Comment #14
aspilicious commentedIn this case yes.
Comment #15
tim.plunkettOkay, now those implementing hook_colors_classes can choose to exclude themselves from classes, and only be in the CSS file.
See the bit in colors.api.php for hook_colors_classes().
Comment #16
tim.plunkettI didn't get anything more accomplished, but I did push up branches. Updated the issue summary.
Comment #17
tim.plunkettI pushed up the alpha7/beta1 version of the upgrade path.
I can adapt the old fullcalendar_colors_update_7200 pretty easily, I just have to add some module_exists calls and use the new API functions. Also, I need to whip up an alpha6 site. That's for tomorrow.
Comment #18
tim.plunkettAlright, tested it from both alpha6 and beta1, everything works great.
The only thing I haven't checked is exactly what happens if you don't get the new colors version before updating fullcalendar.
Comment #19
tim.plunkettOkay, added checks to make sure the updates don't run if Colors is out of date.
Ready for review!
Comment #20
tim.plunkettHere are patches for the less git inclined.
Comment #21
pjcdawkins commentedn00b confusion here:
The fullcalendar patch applies fine. What exactly do you mean by 'latest version' of Colors? I've tried with -dev and -alpha2.
Comment #22
aspilicious commentedTested all the upgrade paths. Works great.
Had lots of troubles with the upgrades:
- Date module changes to much lol
- I had a date contextual filter and that destroyed everything
- Ow yeah and the "broken empty view option" is confusing we should document you don't need to add it anymore
Comment #23
tim.plunkett@pjcdawkins, the Colors module is separate: http://drupal.org/project/colors
@aspilicious, awesome! I'll be sure to document the empty handler part.
Comment #24
tim.plunketthttp://drupalcode.org/project/fullcalendar.git/commit/8b9eb10abfcdecb375...
http://drupalcode.org/project/fullcalendar.git/commit/6be0f7076a2d70bf9e...
http://drupalcode.org/project/fullcalendar.git/commit/e790f3bdc62f2de984...
http://drupalcode.org/project/fullcalendar.git/commit/346770d75666e52d76...
http://drupalcode.org/project/fullcalendar.git/commit/83e438d831494c0043...
http://drupalcode.org/project/fullcalendar.git/commit/3911418917a738eeb0...
Awesome! Tagged a new beta2.
Comment #25
pjcdawkins commented@#23
fullcalendar_update_7201()was insisting I didn't have the latest version of Colors, because I couldn't getcolors-1348538-20.patchto run. But it's working beautifully now with your beta2 release. Thanks!Comment #26.0
(not verified) commentedUpdated issue summary.