My code:
$first = FirstModel::where(\'status\', 1)->get(); SecondModel::whereIn(\'id\', $first->pluck(\'id\')->toArray())->delete();