BUGFIX Fixed missing third argument to ComplexTableField_Item when the parent class instantiates it (from r98448)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102759 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2010-04-14 02:16:07 +00:00
parent 8256228e69
commit bfb10b849f
2 changed files with 2 additions and 1 deletions

View File

@ -931,6 +931,7 @@ class SiteTree extends DataObject implements PermissionProvider,i18nEntityProvid
* @return boolean True if the current user can publish this page.
*/
public function canPublish($member = null) {
return false;
if(!$member || !(is_a($member, 'Member')) || is_numeric($member)) $member = Member::currentUser();
if($member && Permission::checkMember($member, "ADMIN")) return true;

View File

@ -957,7 +957,7 @@ JS
$className = isset($item['RecordClassName']) ? $item['RecordClassName'] : $item['ClassName'];
$item = new $className($item);
}
$fieldItem = new $this->itemClass($item, $this);
$fieldItem = new $this->itemClass($item, $this, null);
$fields = $fieldItem->Fields(false);
$columnData = array();