When a table has lots of columns and may be sorted by any combination of them, it's helpful to display the spread in a consistent order.
This can be accomplished by changing lines 257-260 of views_summarize.module from
foreach ($hist as $value => $count) {
$rows[] = array($value, $count);
}
to
foreach ($hist as $value => $count) {
$rows[$value] = array($value, $count);
}
ksort($rows);
Sorry, I suck at rolling patches, but perhaps someone who finds this useful will roll a patch. Thank you for a great module!!
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | views_summarize-sort_spread_keys-1431710-1.patch | 569 bytes | oadaeh |
Comments
Comment #1
oadaeh commentedI created and attached a patch. I also included the option of doing natural sorts for users of PHP 5.4 or newer.
Comment #2
oadaeh commentedThis has been committed to the 7.x-1.x branch, here: http://drupalcode.org/project/views_summarize.git/commit/2da9372