21 - Laravel route model binding with two dependent model with has many relation

preview_player
Показать описание
#laravel #api

Our current requirement is to have a route which we are showing all the URLs from a collection. This is where we will use a basic route model binding to get the collection and all the URLs which are mapped to that collection.

However, if we want to see a URL which is specifically mapped to a Collection and if that relation is not present, it should show a 404 not found error, that is something which we will have to handle in this video.

You can find me on:
Рекомендации по теме