Last active
March 31, 2021 18:12
-
-
Save notflip/1b2189239bc1cb936bbf2a0d5e592611 to your computer and use it in GitHub Desktop.
Laravel WhereHasNot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function scopeUnClaimed($query) | |
{ | |
return $query->whereHas('claims',function($q) { | |
$q->where('dentist_id', $user->dentist->id); | |
}, '<', 1); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you !!