Is there a generic way to check if a Laravel Model has relationships? -


i trying write generic function fire if model has relationships defined not specific model.

is there property of model tell me if model has relationships regardless of model or relationships?

you have access relations using:

$model->getrelations(); 

Comments

Popular posts from this blog

javascript - addthis share facebook and google+ url -

ios - Show keyboard with UITextField in the input accessory view -

c# - Send Image in Json : 400 Bad request -