src/Charcoal/Admin/Widget/SearchWidget.php
public function dataFromObject()
    {
        $obj             = $this->proto();
        $metadata        = $obj->metadata();
        $adminMetadata   = isset($metadata['admin']) ? $metadata['admin'] : null;
        $collectionIdent = $this->collectionIdent();
        if (!$collectionIdent) {
            $collectionIdent = isset($adminMetadata['default_list']) ? $adminMetadata['default_list'] : '';
        }

        if (isset($adminMetadata['lists'][$collectionIdent])) {
            return $adminMetadata['lists'][$collectionIdent];
        } else {
            return [];
        }
    }
public function dataFromObject()
    {
        $obj             = $this->proto();
        $metadata        = $obj->metadata();
        $adminMetadata   = isset($metadata['admin']) ? $metadata['admin'] : null;
        $collectionIdent = $this->collectionIdent();
        if (!$collectionIdent) {
            $collectionIdent = isset($adminMetadata['default_list']) ? $adminMetadata['default_list'] : '';
        }

        if (isset($adminMetadata['lists'][$collectionIdent])) {
            return $adminMetadata['lists'][$collectionIdent];
        } else {
            return [];
        }
    }
public function dataFromObject ( ) { $ obj = $ this -> proto ( ) ; $ metadata = $ obj -> metadata ( ) ; $ adminMetadata = isset ( $ metadata [ 'admin' ] ) ? $ metadata [ 'admin' ] : null ; $ collectionIdent = $ this -> collectionIdent ( ) ; if ( ! $ collectionIdent ) { $ collectionIdent = isset ( $ adminMetadata [ 'default_list' ] ) ? $ adminMetadata [ 'default_list' ] : '' ; } if ( isset ( $ adminMetadata [ 'lists' ] [ $ collectionIdent ] ) ) { return $ adminMetadata [ 'lists' ] [ $ collectionIdent ] ; } else { return [ ] ; } }
Fetch metadata from current obj_type
@return array List of metadata.
Fetch metadata from current obj_type