mirror of
https://github.com/silverstripe/silverstripe-subsites
synced 2024-10-22 11:05:55 +02:00
MINOR: Fixed test execution for SubsitesVirtualPage
This commit is contained in:
parent
b646a104f1
commit
1dcd84e098
@ -31,9 +31,12 @@ class SubsitesVirtualPage extends VirtualPage {
|
|||||||
"SiteTree"
|
"SiteTree"
|
||||||
);
|
);
|
||||||
$pageSelectionField->setFilterFunction(create_function('$item', 'return $item->ClassName != "VirtualPage";'));
|
$pageSelectionField->setFilterFunction(create_function('$item', 'return $item->ClassName != "VirtualPage";'));
|
||||||
$subsiteID = Controller::curr()->getRequest()->getVar('TreeDropdownField_Form_EditForm_CopyContentFromID_SubsiteID');
|
|
||||||
if($subsiteID) {
|
if(Controller::curr()->getRequest()) {
|
||||||
$pageSelectionField->setSubsiteID($subsiteID);
|
$subsiteID = Controller::curr()->getRequest()->getVar('TreeDropdownField_Form_EditForm_CopyContentFromID_SubsiteID');
|
||||||
|
if($subsiteID) {
|
||||||
|
$pageSelectionField->setSubsiteID($subsiteID);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
$fields->replaceField('CopyContentFromID', $pageSelectionField);
|
$fields->replaceField('CopyContentFromID', $pageSelectionField);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user