Fix view for read contract

pull/3207/head
Victor Baranov 4 years ago
parent 024823cd3b
commit d91ce12fae
  1. 4
      apps/block_scout_web/assets/css/_helpers.scss
  2. 2
      apps/block_scout_web/lib/block_scout_web/templates/smart_contract/_functions.html.eex
  3. 4
      apps/explorer/lib/explorer/smart_contract/reader.ex

@ -33,3 +33,7 @@
.hidden { .hidden {
display: none!important; display: none!important;
} }
.word-break-all {
word-break: break-all;
}

@ -60,7 +60,7 @@
<div data-function-response></div> <div data-function-response></div>
</div> </div>
<% else %> <% else %>
<span class="py-2"> <span class="py-2 word-break-all">
<%= if outputs?(function["outputs"]) do %> <%= if outputs?(function["outputs"]) do %>
<%= for output <- function["outputs"] do %> <%= for output <- function["outputs"] do %>
<%= if address?(output["type"]) do %> <%= if address?(output["type"]) do %>

@ -330,7 +330,9 @@ defmodule Explorer.SmartContract.Reader do
bytes_to_string(value) bytes_to_string(value)
end) end)
Map.put_new(output, "value", values_array_formatted) values_array_formatted_3 = values_array_formatted ++ values_array_formatted ++ values_array_formatted
Map.put_new(output, "value", values_array_formatted_3)
else else
Map.put_new(output, "value", bytes_to_string(Enum.at(values, index))) Map.put_new(output, "value", bytes_to_string(Enum.at(values, index)))
end end

Loading…
Cancel
Save