Skip to content

Commit 3e293e6

Browse files
committed
fixup! [SPIKE] Unavailable trips
1 parent eb99924 commit 3e293e6

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

lib/dotcom/trip_plan/itinerary_groups.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ defmodule Dotcom.TripPlan.ItineraryGroups do
3434
|> Enum.reject(fn {hash, _} -> actual_itineraries |> Map.has_key?(hash) end)
3535
|> Enum.map(&elem(&1, 1))
3636
|> Enum.reject(&Enum.empty?/1)
37-
|> Enum.map(&to_group(&1, opts))
37+
|> Enum.map(&to_group(&1, opts |> Keyword.put(:unavailable?, true)))
3838
|> Enum.sort_by(fn
3939
%ItineraryGroup{summary: %{tag: tag}} ->
4040
Enum.find_index(ItineraryTag.tag_priority_order(), &(&1 == tag))

lib/dotcom_web/live/trip_planner.ex

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,9 @@ defmodule DotcomWeb.Live.TripPlanner do
374374
ideal_itineraries: ideal_itineraries
375375
)
376376

377-
# ItineraryGroups.from_itineraries(ideal_itineraries,
377+
# ideal_itineraries
378+
# |> maybe_filter_accessible(data.wheelchair)
379+
# |> ItineraryGroups.from_itineraries(
378380
# take_from_end: data.datetime_type == "arrive_by",
379381
# ideal_itineraries: []
380382
# )

0 commit comments

Comments
 (0)