application/Espo/Core/Utils/Metadata/Helper.php
public function getFieldDefsByType($fieldDef)
    {
        if (is_string($fieldDef)) {
            $fieldDef = array('type' => $fieldDef);
        }

        if (isset($fieldDef['type'])) {
            return $this->getMetadata()->get('fields.'.$fieldDef['type']);
        }

        return null;
    }
public function getFieldDefsByType($fieldDef)
    {
        if (is_string($fieldDef)) {
            $fieldDef = array('type' => $fieldDef);
        }

        if (isset($fieldDef['type'])) {
            return $this->getMetadata()->get('fields.'.$fieldDef['type']);
        }

        return null;
    }
public function getFieldDefsByType ( $ fieldDef ) { if ( is_string ( $ fieldDef ) ) { $ fieldDef = array ( 'type' => $ fieldDef ) ; } if ( isset ( $ fieldDef [ 'type' ] ) ) { return $ this -> getMetadata ( ) -> get ( 'fields.' . $ fieldDef [ 'type' ] ) ; } return null ; }
Get field defenition by type in metadata, "fields" key

@param  array | string $fieldDef - It can be a string or field defenition from entityDefs
@return array | null
Get field defenition by type in metadata fields key