Core/Orm/Validation/Element/Element.php
private function _getForeignKeyFieldValue($field) {
        $fields = null;

        if (gettype($field->value) != 'object') {
            if (is_array($field->value)) {
                $fields = $field->value;
            }
            else {
                $fields = [$field->value];
            }
        }
        else if (get_class($field->value) != 'System\Collection\Collection') {
            $fields = $field->value->data();
        }
        else if (get_class($field->value) != 'System\Orm\Entity\Type\File') {
            $fields = [$field->value];
        }

        return $fields;
    }
private function _getForeignKeyFieldValue($field) {
        $fields = null;

        if (gettype($field->value) != 'object') {
            if (is_array($field->value)) {
                $fields = $field->value;
            }
            else {
                $fields = [$field->value];
            }
        }
        else if (get_class($field->value) != 'System\Collection\Collection') {
            $fields = $field->value->data();
        }
        else if (get_class($field->value) != 'System\Orm\Entity\Type\File') {
            $fields = [$field->value];
        }

        return $fields;
    }
private function _getForeignKeyFieldValue ( $ field ) { $ fields = null ; if ( gettype ( $ field -> value ) != 'object' ) { if ( is_array ( $ field -> value ) ) { $ fields = $ field -> value ; } else { $ fields = [ $ field -> value ] ; } } else if ( get_class ( $ field -> value ) != 'System\Collection\Collection' ) { $ fields = $ field -> value -> data ( ) ; } else if ( get_class ( $ field -> value ) != 'System\Orm\Entity\Type\File' ) { $ fields = [ $ field -> value ] ; } return $ fields ; }
The method _getField return the value of each field in the Entity. This method is used to factorize the source code
@access public
@param $field \Gcs\Framework\Core\Orm\Entity\Field
@return mixed array
@since 3.0
@package Gcs\Framework\Core\Form\Validation\Element
The method _getField return the value of each field in the Entity . This method is used to factorize the source code