Skip to content

Commit

Permalink
Versioned awareness in DashboardModelAdminPanel
Browse files Browse the repository at this point in the history
  • Loading branch information
Uncle Cheese committed Feb 4, 2014
1 parent e857c49 commit e0abe23
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions code/panels/DashboardModelAdminPanel.php
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,10 @@ public function PluralModelName() {
*/
public function ModelAdminItems() {
if($this->ModelAdminModel) {
$SNG= Injector::inst()->get($this->ModelAdminModel);
if($SNG->hasExtension("Versioned")) {
Versioned::reading_stage("Stage");
}
$records = DataList::create($this->ModelAdminModel)
->limit($this->Count)
->sort("LastEdited DESC");
Expand Down

0 comments on commit e0abe23

Please sign in to comment.