If your customizedExercises input is an array, it is that you need to loop thru eg,
Route::post('/api/customized-exercises',function() {
$created = [];
foreach(Request->customizedExercises as $exercise) {
$created[] = App\CustomizedExercise::create($exercise);
};
return $created;
});
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community