Example #1
0
 public function searchVictims($searchType, $searchStr)
 {
     $victims = Victim::where($searchType, 'LIKE', $searchStr)->get();
     if ($victims) {
         return $victims;
     }
     return null;
 }
Example #2
0
 public function checkIfExists(Request $request)
 {
     $data = $request->all();
     if (Victim::where('victimId', '=', $data['victimId'])->exists()) {
         return "false";
     }
     return "true";
 }