Move forms into ExplorerWeb namespace

pull/118/head
Luke Imhoff 7 years ago
parent 06a3b56f9b
commit 5e53958424
  1. 2
      apps/explorer_web/lib/explorer_web/controllers/address_transaction_from_controller.ex
  2. 2
      apps/explorer_web/lib/explorer_web/controllers/address_transaction_to_controller.ex
  3. 2
      apps/explorer_web/lib/explorer_web/controllers/block_controller.ex
  4. 2
      apps/explorer_web/lib/explorer_web/controllers/block_transaction_controller.ex
  5. 2
      apps/explorer_web/lib/explorer_web/controllers/pending_transaction_controller.ex
  6. 3
      apps/explorer_web/lib/explorer_web/controllers/transaction_controller.ex
  7. 3
      apps/explorer_web/lib/explorer_web/controllers/transaction_log_controller.ex
  8. 2
      apps/explorer_web/lib/explorer_web/forms/block_form.ex
  9. 2
      apps/explorer_web/lib/explorer_web/forms/pending_transaction_form.ex
  10. 2
      apps/explorer_web/lib/explorer_web/forms/transaction_form.ex
  11. 5
      apps/explorer_web/test/explorer_web/forms/block_form_test.exs
  12. 4
      apps/explorer_web/test/explorer_web/forms/pending_transaction_form_test.exs
  13. 4
      apps/explorer_web/test/explorer_web/forms/transaction_form_test.exs

@ -9,7 +9,7 @@ defmodule ExplorerWeb.AddressTransactionFromController do
alias Explorer.Repo.NewRelic, as: Repo
alias Explorer.Transaction
alias Explorer.Transaction.Service.Query
alias Explorer.TransactionForm
alias ExplorerWeb.TransactionForm
def index(conn, %{"address_id" => address_id} = params) do
address = Address.by_hash(address_id)

@ -9,7 +9,7 @@ defmodule ExplorerWeb.AddressTransactionToController do
alias Explorer.Repo.NewRelic, as: Repo
alias Explorer.Transaction
alias Explorer.Transaction.Service.Query
alias Explorer.TransactionForm
alias ExplorerWeb.TransactionForm
def index(conn, %{"address_id" => address_id} = params) do
address = Address.by_hash(address_id)

@ -4,8 +4,8 @@ defmodule ExplorerWeb.BlockController do
import Ecto.Query
alias Explorer.Block
alias Explorer.BlockForm
alias Explorer.Repo.NewRelic, as: Repo
alias ExplorerWeb.BlockForm
def index(conn, params) do
blocks =

@ -5,7 +5,7 @@ defmodule ExplorerWeb.BlockTransactionController do
alias Explorer.Repo.NewRelic, as: Repo
alias Explorer.Transaction
alias Explorer.TransactionForm
alias ExplorerWeb.TransactionForm
def index(conn, %{"block_id" => block_number} = params) do
query =

@ -5,7 +5,7 @@ defmodule ExplorerWeb.PendingTransactionController do
alias Explorer.Repo.NewRelic, as: Repo
alias Explorer.Transaction
alias Explorer.PendingTransactionForm
alias ExplorerWeb.PendingTransactionForm
def index(conn, %{"last_seen" => last_seen} = _) do
query =

@ -3,12 +3,11 @@ defmodule ExplorerWeb.TransactionController do
import Ecto.Query
alias Explorer.Log
alias Explorer.Repo.NewRelic, as: Repo
alias Explorer.Transaction
alias Explorer.TransactionForm
alias Explorer.Transaction.Service
alias Explorer.Transaction.Service.Query
alias ExplorerWeb.TransactionForm
def index(conn, %{"last_seen" => last_seen}) do
query =

@ -6,9 +6,8 @@ defmodule ExplorerWeb.TransactionLogController do
alias Explorer.Log
alias Explorer.Repo.NewRelic, as: Repo
alias Explorer.Transaction
alias Explorer.TransactionForm
alias Explorer.Transaction.Service
alias Explorer.Transaction.Service.Query
alias ExplorerWeb.TransactionForm
def index(conn, %{"transaction_id" => transaction_id}) do
transaction_hash = String.downcase(transaction_id)

@ -1,4 +1,4 @@
defmodule Explorer.BlockForm do
defmodule ExplorerWeb.BlockForm do
@moduledoc false
alias Explorer.Block
alias Explorer.BlockTransaction

@ -1,4 +1,4 @@
defmodule Explorer.PendingTransactionForm do
defmodule ExplorerWeb.PendingTransactionForm do
@moduledoc "Format a pending Transaction for display."
import ExplorerWeb.Gettext

@ -1,4 +1,4 @@
defmodule Explorer.TransactionForm do
defmodule ExplorerWeb.TransactionForm do
@moduledoc "Format a Block and a Transaction for display."
import Ecto.Query

@ -1,6 +1,7 @@
defmodule Explorer.BlockFormTest do
defmodule ExplorerWeb.BlockFormTest do
use Explorer.DataCase
alias Explorer.BlockForm
alias ExplorerWeb.BlockForm
describe "build/1" do
test "that it has a number" do

@ -1,7 +1,7 @@
defmodule Explorer.PendingTransactionFormTest do
defmodule ExplorerWeb.PendingTransactionFormTest do
use Explorer.DataCase
alias Explorer.PendingTransactionForm
alias ExplorerWeb.PendingTransactionForm
describe "build/1" do
test "returns a successful transaction when there is a successful receipt" do

@ -1,7 +1,7 @@
defmodule Explorer.TransactionFormTest do
defmodule ExplorerWeb.TransactionFormTest do
use Explorer.DataCase
alias Explorer.TransactionForm
alias ExplorerWeb.TransactionForm
describe "build/1" do
test "returns a successful transaction when there is a successful receipt" do

Loading…
Cancel
Save