Updated Member's getCMSFields() to consistently work with fields in a tab

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@63837 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sam Minnee 2008-10-08 04:17:52 +00:00
parent 7741fdb155
commit 7efd56e0dd

View File

@ -910,7 +910,8 @@ class Member extends DataObject {
* editing this member.
*/
public function getCMSFields() {
$fields = parent::scaffoldCMSFields();
$mainFields = parent::scaffoldCMSFields();
$fields = $mainFields->fieldByName("Root")->fieldByName("Main")->Children;
$password = new ConfirmedPasswordField('Password', 'Password');
$password->setCanBeEmpty(true);
@ -960,9 +961,9 @@ class Member extends DataObject {
// Members are displayed within group edit form in SecurityAdmin
$fields->removeByName('Groups');
$this->extend('updateCMSFields', $fields);
$this->extend('updateCMSFields', $mainFields);
return $fields;
return $mainFields;
}
function fieldLabels() {