mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
BUGFIX Adjusted ForeignKey->scaffoldFormField() to new scaffolding notation ("ajaxSafe" instead of "ajax")
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@64239 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
d5a37d40dd
commit
2d33fd160a
@ -27,13 +27,13 @@ class ForeignKey extends Int {
|
||||
$hasOneClass = $this->object->has_one($relationName);
|
||||
|
||||
if($hasOneClass && singleton($hasOneClass) instanceof Image) {
|
||||
if(isset($params['ajax']) && $params['ajax']) {
|
||||
if(isset($params['ajaxSafe']) && $params['ajaxSafe']) {
|
||||
$field = new ImageField($relationName, $title, $this->value);
|
||||
} else {
|
||||
$field = new SimpleImageField($relationName, $title, $this->value);
|
||||
}
|
||||
} elseif($hasOneClass && singleton($hasOneClass) instanceof File) {
|
||||
if(isset($params['ajax']) && $params['ajax']) {
|
||||
if(isset($params['ajaxSafe']) && $params['ajaxSafe']) {
|
||||
$field = new FileIframeField($relationName, $title, $this->value);
|
||||
} else {
|
||||
$field = new FileField($relationName, $title, $this->value);
|
||||
|
Loading…
Reference in New Issue
Block a user