mirror of
https://github.com/silverstripe/silverstripe-versionfeed
synced 2024-10-22 11:05:31 +02:00
Merge pull request #35 from chillu/pulls/VersionFeedFunctionalTest-sort-fix
Consistent sorting for getDiffList()
This commit is contained in:
commit
898c281ef5
@ -61,7 +61,9 @@ class VersionFeed extends SiteTreeExtension {
|
|||||||
// Get just enough elements for diffing. We need one more than desired to have something to compare to.
|
// Get just enough elements for diffing. We need one more than desired to have something to compare to.
|
||||||
$qLimit = (int)$limit + 1;
|
$qLimit = (int)$limit + 1;
|
||||||
$versions = $this->owner->allVersions(
|
$versions = $this->owner->allVersions(
|
||||||
"\"WasPublished\"='1' AND \"CanViewType\" IN ('Anyone', 'Inherit') $offset", "\"LastEdited\" DESC", $qLimit
|
"\"WasPublished\"='1' AND \"CanViewType\" IN ('Anyone', 'Inherit') $offset",
|
||||||
|
"\"SiteTree\".\"LastEdited\" DESC, \"SiteTree\".\"ID\" DESC",
|
||||||
|
$qLimit
|
||||||
);
|
);
|
||||||
|
|
||||||
// Process the list to add the comparisons.
|
// Process the list to add the comparisons.
|
||||||
|
Loading…
Reference in New Issue
Block a user