Braintree\TransactionGateway::fetch PHP Method

fetch() public method

public fetch ( $query, $ids )
    public function fetch($query, $ids)
    {
        $criteria = [];
        foreach ($query as $term) {
            $criteria[$term->name] = $term->toparam();
        }
        $criteria["ids"] = TransactionSearch::ids()->in($ids)->toparam();
        $path = $this->_config->merchantPath() . '/transactions/advanced_search';
        $response = $this->_http->post($path, ['search' => $criteria]);
        return Util::extractattributeasarray($response['creditCardTransactions'], 'transaction');
    }