From bf6205f64cd11ed330ab1190a5140759f2e60f25 Mon Sep 17 00:00:00 2001 From: skanderm Date: Tue, 3 Dec 2024 14:50:52 -0800 Subject: [PATCH] Add public relationships to feed_streams (#731) --- server/lib/orcasite/radio/feed_stream.ex | 25 +++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/server/lib/orcasite/radio/feed_stream.ex b/server/lib/orcasite/radio/feed_stream.ex index e44fee92..4ad2f032 100644 --- a/server/lib/orcasite/radio/feed_stream.ex +++ b/server/lib/orcasite/radio/feed_stream.ex @@ -57,14 +57,28 @@ defmodule Orcasite.Radio.FeedStream do end relationships do - belongs_to :feed, Orcasite.Radio.Feed - belongs_to :prev_feed_stream, Orcasite.Radio.FeedStream - belongs_to :next_feed_stream, Orcasite.Radio.FeedStream + belongs_to :feed, Orcasite.Radio.Feed do + public? true + end + + belongs_to :prev_feed_stream, Orcasite.Radio.FeedStream do + public? true + end + + belongs_to :next_feed_stream, Orcasite.Radio.FeedStream do + public? true + end - has_many :feed_segments, Orcasite.Radio.FeedSegment - has_many :bout_feed_streams, Orcasite.Radio.BoutFeedStream + has_many :feed_segments, Orcasite.Radio.FeedSegment do + public? true + end + + has_many :bout_feed_streams, Orcasite.Radio.BoutFeedStream do + public? true + end many_to_many :bouts, Orcasite.Radio.Bout do + public? true through Orcasite.Radio.BoutFeedStream end end @@ -413,6 +427,7 @@ defmodule Orcasite.Radio.FeedStream do graphql do type :feed_stream + attribute_types feed_id: :string, prev_feed_stream_id: :string, next_feed_stream_id: :string queries do list :feed_streams, :index