public function getList(array $options)
    {
        $result = null;
        $this->hook->attach('translation.entity.list.before', $options, $result, $this);

        if (isset($result)) {
            return (array) $result;
        }

        $table = $this->getTable($options['entity']);
        $sql = "SELECT * FROM `$table` WHERE {$options['entity']}_id = ?";

        $conditions = array($options['entity_id']);

        if (isset($options['language'])) {
            $sql .= ' AND language = ?';
            $conditions[] = $options['language'];
        }

        $result = $this->db->fetchAll($sql, $conditions);
        $this->hook->attach('translation.entity.list.after', $options, $result, $this);
        return (array) $result;
    }
public function getList(array $options)
    {
        $result = null;
        $this->hook->attach('translation.entity.list.before', $options, $result, $this);

        if (isset($result)) {
            return (array) $result;
        }

        $table = $this->getTable($options['entity']);
        $sql = "SELECT * FROM `$table` WHERE {$options['entity']}_id = ?";

        $conditions = array($options['entity_id']);

        if (isset($options['language'])) {
            $sql .= ' AND language = ?';
            $conditions[] = $options['language'];
        }

        $result = $this->db->fetchAll($sql, $conditions);
        $this->hook->attach('translation.entity.list.after', $options, $result, $this);
        return (array) $result;
    }
public function getList ( array $ options ) { $ result = null ; $ this -> hook -> attach ( 'translation.entity.list.before' , $ options , $ result , $ this ) ; if ( isset ( $ result ) ) { return ( array ) $ result ; } $ table = $ this -> getTable ( $ options [ 'entity' ] ) ; $ sql = "SELECT * FROM `$table` WHERE {$options['entity']}_id = ?" ; $ conditions = array ( $ options [ 'entity_id' ] ) ; if ( isset ( $ options [ 'language' ] ) ) { $ sql .= ' AND language = ?' ; $ conditions [ ] = $ options [ 'language' ] ; } $ result = $ this -> db -> fetchAll ( $ sql , $ conditions ) ; $ this -> hook -> attach ( 'translation.entity.list.after' , $ options , $ result , $ this ) ; return ( array ) $ result ; }
Returns an array of translations
@param array $options
@return array
Returns an array of translations