Active
Project:
Timeline
Version:
6.x-2.1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
30 Apr 2012 at 14:39 UTC
Updated:
30 Apr 2012 at 14:39 UTC
Using grouping is great for colour coding the graphs but if the order in the resulting sets is different from the order of rows in the views' results fields get muddled in the bubbles. A bit difficult to reproduce but the problem lies somewhere around this loop in Timeline.class.inc
function getEvents() {
..
if (!empty($this->view->result)) {
$this->view->row_index = 0;
foreach ($this->sets as $k => $set) {
$css_selector = $this->generateCssSelector();
$color = FALSE;
if (isset($this->view->style_options['grouping']) && $this->view->style_options['grouping'] != '') {
$color = $this->getColor();
}
foreach ($set as $row) {
$event = new TimelineEvent($this->view, $row, $this->dateformat, $css_selector, $color);
if ($event->getData()) {
$events[] = $event->getData();
}
$this->view->row_index++;
}
}
}
As a workaround I've used the same criterium for ordering as for grouping.