addressalign-toparrow-leftarrow-rightbackbellblockcalendarcameraccwcheckchevron-downchevron-leftchevron-rightchevron-small-downchevron-small-leftchevron-small-rightchevron-small-upchevron-upcircle-with-checkcircle-with-crosscircle-with-pluscrossdots-three-verticaleditemptyheartexporteye-with-lineeyefacebookfolderfullheartglobegmailgooglegroupshelp-with-circleimageimagesinstagramFill 1linklocation-pinm-swarmSearchmailmessagesminusmoremuplabelShape 3 + Rectangle 1ShapeoutlookpersonJoin Group on CardStartprice-ribbonprintShapeShapeShapeShapeImported LayersImported LayersImported Layersshieldstartickettrashtriangle-downtriangle-uptwitteruserwarningyahoo

An Introduction to Model Relationships in Laravel.

We're back from a long break so, let's get into some tasty new topics!

We'll jump a bit further into the deep end w/ Laravel.

Dan Trenz will be giving an introduction to Eloquent model relationships in Laravel.

By defining relationships between your models, complex queries for fetching/creating/updating related items for a given model become trivial.

For example, fetching a blog post, as well as the author of the post, and all of the comments attached to the post could potentially be reduced down to a single line of code.

We'll cover basic relationships, such as;

• One to One

• One to Many

• Many to Many

We'll also cover more complex relationships, introduced in the last month w/ the release of Laravel 4.1, such as;

• Has Many Through

• Polymorphic Relations

Sorry for the late notice, but we hope you will be able to join us to discuss these bleeding edge PHP topics.

Note: We are assuming that the audience for this topic is familiar with MVC frameworks. We will also be using database migrations & seeders to set-up our app for the live-coding demo, but we will NOT be covering their use in detail for this talk.



Join or login to comment.

  • Changming F.

    Thanks Dan!

    January 21, 2014

  • Dan T.

    As promised, here is a follow up blog post that summarizes the first two-thirds of this talk - regarding model relationships in Laravel 4.0: http://codeplanet.io/laravel-model-relationships-pt-1/

    The article also includes a link to the demo project I used during the talk, on Github.

    Laravel 4.1 model relationships will be covered in a "Part 2" post soon.

    January 21, 2014

  • Andrew K.

    Great topic, Dan

    January 15, 2014

16 went

Our Sponsors

  • Nutshell

    Stickers, beer, pizza, comfy hangout spot.

  • Washtenaw Community College

    We're grateful to WCC for providing a meeting space.

  • Renowned Media

    Meetup Recurring Fees

People in this
Meetup are also in:

Sign up

Meetup members, Log in

By clicking "Sign up" or "Sign up using Facebook", you confirm that you accept our Terms of Service & Privacy Policy