ENHANCEMENT: Add GridfieldLevelup component to files area

This commit is contained in:
Naomi Guyer 2012-06-26 15:53:39 +12:00 committed by Ingo Schommer
parent bb5e3e5fbd
commit ef651d9d93
2 changed files with 6 additions and 3 deletions

View File

@ -146,7 +146,8 @@ JS
new GridFieldPaginator(15),
new GridFieldEditButton(),
new GridFieldDeleteAction(),
new GridFieldDetailForm()
new GridFieldDetailForm(),
GridFieldLevelup::create($folder->ID)->setLinkSpec('admin/assets/show/%d')
);
$gridField = new GridField('File', $title, $this->getList(), $gridFieldConfig);

View File

@ -676,7 +676,9 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr
);
if($parentID){
$gridFieldConfig->addComponent(
new GridFieldLevelup($parentID)
GridFieldLevelup::create($parentID)
->setLinkSpec('?ParentID=%d&view=list')
->setAttributes(array('data-pjax' => 'ListViewForm,Breadcrumbs'))
);
}
$gridField = new GridField('Page','Pages', $list, $gridFieldConfig);