I'm using Panels (7.x-3.0-alpha3), Timeline (7.x-3.x-dev), and Views (7.x-3.0-rc3) with Drupal 7.12. I created a Timeline, which works great when displayed as a Page. However, what I would like to do is add a Timeline block to my homepage, which is, of course, built with Panels.

When I try to add the Timeline block (as content) to a region on my Homepage Panel, it is not an option. It does show under my Blocks administration page and I can add it to my site this way.

Does Timeline work with Panels? Am I missing a step?

Comments

allio_froggio’s picture

I got this to work by using an attachment with a block. When I display the timeline as a page, there's no issue. But when I display it in a block (using panels), I get a series of errors like this:

Notice: Undefined index: granularity in theme_date_display_combination() (line 147 of ).
Notice: Undefined variable: class in include() (line 8 of ).
Notice: Undefined variable: width in include() (line 8 of ).
Notice: Undefined variable: class in include() (line 10 of ).
Notice: Undefined variable: timeline_theme in include() (line 10 of ).
Notice: Undefined variable: height in include() (line 10 of ).
Notice: Undefined variable: class in include() (line 8 of ).
Notice: Undefined variable: width in include() (line 8 of ).
Notice: Undefined variable: class in include() (line 10 of ).
Notice: Undefined variable: timeline_theme in include() (line 10 of ).
Notice: Undefined variable: height in include() (line 10 of ).
Notice: Undefined variable: class in include() (line 8 of ).
Notice: Undefined variable: width in include() (line 8 of ).
Notice: Undefined variable: class in include() (line 10 of ).
Notice: Undefined variable: timeline_theme in include() (line 10 of ).
Notice: Undefined variable: height in include() (line 10 of ).

Any ideas?

cabplan’s picture

So I really do not have an answer to your issue but I have a question for you that maybe you can help me with, How did you get the timeline working? I have downloaded and activated: Panels (7.x-3.2), Timeline (7.x-3.x-dev), and Views (7.x-3.0-rc3). I also downloaded the installed both js files into the libraries simile_timeline directory. I created a new content type called Timeline Event, that has a Date field, and I created a View called Timeline View but when I try to edit the settings of the Timeline, in the field usage section I cannot choose a Start Date, even after I select my Date field. Can you please help me on how you got this module to work, my view has a ton of errors:

Notice: Undefined index: bands in Timeline->__construct() (line 44 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: bands in Timeline->getBands() (line 101 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: bands in Timeline->__construct() (line 48 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: bands in Timeline->__construct() (line 49 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: bands in Timeline->__construct() (line 50 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: display in Timeline->__construct() (line 55 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: display in Timeline->__construct() (line 56 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: display in Timeline->__construct() (line 57 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/includes/Timeline.class.inc).
Notice: Undefined index: display in timeline_views_plugin_style->render() (line 397 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/timeline_views_plugin_style.inc).
Notice: Undefined index: display in timeline_views_plugin_style->render() (line 398 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/timeline_views_plugin_style.inc).
Notice: Undefined variable: class in include() (line 8 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/views-view-timeline.tpl.php).
Notice: Undefined variable: width in include() (line 8 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/views-view-timeline.tpl.php).
Notice: Undefined variable: class in include() (line 10 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/views-view-timeline.tpl.php).
Notice: Undefined variable: timeline_theme in include() (line 10 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/views-view-timeline.tpl.php).
Notice: Undefined variable: height in include() (line 10 of /home/content/10/7715610/html/tonyvalle/sites/all/modules/timeline/views-view-timeline.tpl.php).

and at the bottom it says: There is no data available to show on the timeline

I have two pieces of Timeline event content. Can anyone please help me. Sorry for busting in on your issue thread but i thought you could possibly help me.

cabplan’s picture

Ok so I found out how to get the Start date to let me actually select something, I have to add "Post Date" field to the fields, but then I can only choose Post Date in the Start date field, I cannot choose my "From" field I created. I do not get an error anymore but the page is just blank,

I downloaded and install CCK 7.x dev but that did not do anything either, I get this error on the Content page:

Warning: file_get_contents(/sites/all/libraries/simile_timeline/timeline_js/timeline-api.js) [function.file-get-contents]: failed to open stream: No such file or directory in drupal_build_js_cache() (line 4817 of /home/content/10/7715610/html/tonyvalle/includes/common.inc).

Any help would be most appreciated.

allio_froggio’s picture

First, is your issue specifically with Panels or just displaying the timeline view anywhere on your site?

So, I'm not sure if I did any of this the correct way, but, here's what I did (as best as I can remember).

  1. Created a date field. I used the select list widget (even thought I prefer the pop up calendar because I remember reading some instructions to do that). I'm wondering if you can only use the system post date field because your date field is not the correct widget??? (My version of the Date module is 7.x-2.2.)
  2. Created a timeline style page view. I'm putting in a link here to show you what my view looks like exactly, because sometimes seeing a picture is just better. My Timeline views
  3. I played a lot with the settings for display. But those are of course just personal preference (and I haven't gotten into theming at all...)
  4. I turned off error notification. The "errors" that I was getting above were really just notices, so, I didn't need to see them anymore.

Now, here are things I didn't do:

  1. I didn't create a timeline specifc piece of content. In fact, I have three different content types (all using the same date field - added using "Add an Exisiting Field" to each content type) and each of these are colour coded on the actual timeline (which I think is awesome!). I don't see why this would make a difference whatsover, but I thought I'd throw it out there.

Things that are still an issue:

  1. The summary band does not actually display date accurately. For example, a node that is tagged as "1935" will show up in the decade band of "1950." Who knows on that one, I might just remove the summary band.
  2. The exposed filter is a little wonky. But, I'm leaving it for now.
jindustry’s picture

cabplan's problem seems seems like it might be adressed with this fix: http://drupal.org/node/1512100.