Skip to content

Commit 05d5048

Browse files
committed
rename schema to better express intent
1 parent a11f962 commit 05d5048

File tree

5 files changed

+10
-9
lines changed

5 files changed

+10
-9
lines changed

lib/algora/bounties/ticket_view.ex renamed to lib/algora/bounties/schemas/bounty_listing.ex

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
defmodule Algora.Bounties.TicketView do
1+
defmodule Algora.Bounties.BountyListing do
2+
@moduledoc false
23
use Algora.Schema
34

45
import Ecto.Query
@@ -8,7 +9,7 @@ defmodule Algora.Bounties.TicketView do
89
alias Algora.Workspace.Ticket
910

1011
@primary_key false
11-
typed_schema "ticket_views" do
12+
typed_schema "bounty_listings" do
1213
# Denormalized fields from Ticket
1314
field :title, :string
1415
field :number, :integer

lib/algora_web/live/bounties_live.ex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,12 @@ defmodule AlgoraWeb.BountiesLive do
4646

4747
defp assign_tickets(socket) do
4848
tickets =
49-
Bounties.TicketView.list(
49+
Bounties.BountyListing.list(
5050
status: :open,
5151
tech_stack: socket.assigns.current_user.tech_stack,
5252
limit: 100
5353
) ++
54-
Bounties.TicketView.sample_tickets()
54+
Bounties.BountyListing.sample_tickets()
5555

5656
assign(socket, :tickets, tickets)
5757
end

lib/algora_web/live/community/dashboard_live.ex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,12 +305,12 @@ defmodule AlgoraWeb.Community.DashboardLive do
305305

306306
defp assign_tickets(socket) do
307307
tickets =
308-
Bounties.TicketView.list(
308+
Bounties.BountyListing.list(
309309
status: :open,
310310
tech_stack: socket.assigns.current_user.tech_stack,
311311
limit: 100
312312
) ++
313-
Bounties.TicketView.sample_tickets()
313+
Bounties.BountyListing.sample_tickets()
314314

315315
assign(socket, :tickets, Enum.take(tickets, 6))
316316
end

lib/algora_web/live/swift_bounties_live.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ defmodule AlgoraWeb.SwiftBountiesLive do
368368

369369
defp assign_tickets(socket) do
370370
tickets =
371-
Bounties.TicketView.list(
371+
Bounties.BountyListing.list(
372372
status: :open,
373373
tech_stack: ["Swift"],
374374
limit: 100

lib/algora_web/live/user/dashboard_live.ex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,12 +217,12 @@ defmodule AlgoraWeb.User.DashboardLive do
217217

218218
defp assign_tickets(socket) do
219219
tickets =
220-
Bounties.TicketView.list(
220+
Bounties.BountyListing.list(
221221
status: :open,
222222
tech_stack: socket.assigns.current_user.tech_stack,
223223
limit: 100
224224
) ++
225-
Bounties.TicketView.sample_tickets()
225+
Bounties.BountyListing.sample_tickets()
226226

227227
assign(socket, :tickets, Enum.take(tickets, 6))
228228
end

0 commit comments

Comments
 (0)