public function getLocalizedRelationField($fieldName, $locale)
    {
        $baseName = $this->getBasename($fieldName);
        $localizedFieldName = self::localized_field($fieldName, $locale);

        $field = null;

        if ($field = $this->getFieldForRelation($fieldName)) {
            $relationField = clone $field;
            $relationField->setName($localizedFieldName);
            return $relationField;
        }

    }
public function getLocalizedRelationField($fieldName, $locale)
    {
        $baseName = $this->getBasename($fieldName);
        $localizedFieldName = self::localized_field($fieldName, $locale);

        $field = null;

        if ($field = $this->getFieldForRelation($fieldName)) {
            $relationField = clone $field;
            $relationField->setName($localizedFieldName);
            return $relationField;
        }

    }
public function getLocalizedRelationField ( $ fieldName , $ locale ) { $ baseName = $ this -> getBasename ( $ fieldName ) ; $ localizedFieldName = self :: localized_field ( $ fieldName , $ locale ) ; $ field = null ; if ( $ field = $ this -> getFieldForRelation ( $ fieldName ) ) { $ relationField = clone $ field ; $ relationField -> setName ( $ localizedFieldName ) ; return $ relationField ; } }
Get a form field for the given relation name

@todo  default field for has_one?

@param string $fieldName
@param string $locale
@return FormField
Get a form field for the given relation name