$arr = str_replace('"','', $request->course_id);
$arr = str_replace('"','', $request->stream_id);
$arr = str_replace('[','', $arr);
$arr = str_replace(']','', $arr);
$arr = explode(',',$arr);
$a = array(College::whereIn('course_id',$arr)->get());
$b = array(College::whereIn('stream_id',$arr)->get());
$result = array_merge($arr,$a, $b );
return $result;
This is code i done, but not get exact result which i want, i want to filter like when pass id course id 1 and value BCA then show BCA college list, college is 1 table and course is another table and common id in both table is course id, what is exact problem in this code
from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/pdgxoAO
via IFTTT
Aucun commentaire:
Enregistrer un commentaire