Skip to main content

All Questions

0 votes
2 answers
119 views

Filter one record in table with Request ID

I have tabel request_process as follows: requestID Status 1 0 1 1 1 2 2 0 2 1 I want to get one row per request with maximum status but only ...
Muhammad Muazzam's user avatar
8 votes
2 answers
6k views

Laravel return all the ids of descendants

How do I return all the ids of AllSubSections (all levels) class Section extends Model { public function Ads() { return $this->hasMany(Ad::class); } public function ...
Abanoub's user avatar
  • 3,839
2 votes
2 answers
20k views

Laravel pass parameters from controller to Model using 'With' clause

I am new in Laravel, I want to pass the the $id from my controller in the model using with clause My model class Menucategory extends Model { protected $fillable = ['title', 'parent_id', '...
Xabir's user avatar
  • 81