BUGFIX: Changed form fields that call renderWith in Field() to call parent::Field() instead (#5783)

This commit is contained in:
Ed Chipman 2016-07-07 15:55:37 -03:00 committed by Daniel Hensby
parent 27cea80b15
commit 4aa1fc2d2c
6 changed files with 7 additions and 11 deletions

View File

@ -54,9 +54,7 @@ class CheckboxSetField extends OptionsetField {
'Options' => $this->getOptions()
));
return $this->customise($properties)->renderWith(
$this->getTemplates()
);
return FormField::Field($properties);
}
/**

View File

@ -102,7 +102,7 @@ class ListboxField extends DropdownField {
'Options' => new ArrayList($options)
));
return $this->customise($properties)->renderWith($this->getTemplates());
return FormField::Field($properties);
}
public function getAttributes() {

View File

@ -83,9 +83,7 @@ class OptionsetField extends DropdownField {
'Options' => new ArrayList($options)
));
return $this->customise($properties)->renderWith(
$this->getTemplates()
);
return FormField::Field($properties);
}
/**

View File

@ -248,7 +248,7 @@ class TreeDropdownField extends FormField {
)
);
return $this->customise($properties)->renderWith('TreeDropdownField');
return parent::Field($properties);
}
public function extraClass() {

View File

@ -135,7 +135,7 @@ class TreeMultiselectField extends TreeDropdownField {
'Value' => $value
)
);
return $this->customise($properties)->renderWith('TreeDropdownField');
return FormField::Field($properties);
}
/**

View File

@ -972,11 +972,11 @@ class UploadField extends FileField {
}
$mergedConfig = array_merge($config, $this->ufConfig);
return $this->customise(array(
return parent::Field(array(
'configString' => str_replace('"', """, Convert::raw2json($mergedConfig)),
'config' => new ArrayData($mergedConfig),
'multiple' => $allowedMaxFileNumber !== 1
))->renderWith($this->getTemplates());
));
}
/**