add pilot
This commit is contained in:
@@ -95,10 +95,12 @@ class FleetsController extends Controller
|
||||
}
|
||||
|
||||
public function addPilot($fleetId, $charId) {
|
||||
$newPilot = new Fleet();
|
||||
|
||||
//Retrieve the fleet data
|
||||
$fleet = DB::table('Fleets')->where('fleet', $fleetId)->get();
|
||||
//Add a pilot to the fleet
|
||||
$error = $fleet->AddPilot($fleet[0]->character_id, $charId);
|
||||
$error = $newPilot->AddPilot($fleet[0]->character_id, $charId);
|
||||
|
||||
return redirect('/fleets/display');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user