Query Help

Posted 3 months ago by madsynn

Have 3 models

  └── Player
         └── Channel

Server   hasManyThrough 🠊 Cs::class 🠊 Channel::class
Cs       belongsTo 🠊 Server::class ⭢ server_id
Cs       hasOne 🠊 Cs::class 
Channel  belongsTo 🠊 Cs::class ⭢ cs_id

I need help getting name of Channel in the Server

something like this?

$channels = Server::latest()->with->csi->where->channel;

Any help welcome

Please sign in or create an account to participate in this conversation.