|
|
@ -1043,7 +1043,6 @@ defmodule Explorer.Chain do |
|
|
|
query = |
|
|
|
query = |
|
|
|
from(token in Token, |
|
|
|
from(token in Token, |
|
|
|
where: fragment("to_tsvector('english', symbol || ' ' || name ) @@ to_tsquery(?)", ^term_final), |
|
|
|
where: fragment("to_tsvector('english', symbol || ' ' || name ) @@ to_tsquery(?)", ^term_final), |
|
|
|
limit: 5, |
|
|
|
|
|
|
|
select: %{ |
|
|
|
select: %{ |
|
|
|
contract_address_hash: token.contract_address_hash, |
|
|
|
contract_address_hash: token.contract_address_hash, |
|
|
|
symbol: token.symbol, |
|
|
|
symbol: token.symbol, |
|
|
@ -1066,7 +1065,6 @@ defmodule Explorer.Chain do |
|
|
|
query = |
|
|
|
query = |
|
|
|
from(smart_contract in SmartContract, |
|
|
|
from(smart_contract in SmartContract, |
|
|
|
where: fragment("to_tsvector('english', name ) @@ to_tsquery(?)", ^term_final), |
|
|
|
where: fragment("to_tsvector('english', name ) @@ to_tsquery(?)", ^term_final), |
|
|
|
limit: 5, |
|
|
|
|
|
|
|
select: %{contract_address_hash: smart_contract.address_hash, name: smart_contract.name} |
|
|
|
select: %{contract_address_hash: smart_contract.address_hash, name: smart_contract.name} |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|