I have this error:
ErrorException in PuntuacionesCtrl.php line 70: Illegal string offset 'activity_id'
and I do not know how to solve it, this is my code, the first line is 70 where I get the error:
$actividad_id = $request->detalle['actividad_id'];
$puntos = $request->detalle['puntos'];
$cont= 0;
while($cont < count($actividad_id)){
$detalle = new Detalle();
$detalle->puntuacion_id= $puntuacion->id;
$detalle->actividad_id= $actividad_id[$cont];
$detalle->puntos= $puntos[$cont];
$detalle->save();
$cont=$cont + 1;
}
so I have it in the form:
<select multiple class="form-control" name="actividad_id" ng-model="puntuacion.detalle.actividad_id" ng-options="actividad.id as actividad.nombre for actividad in actividades | filter:{ circular_id: puntuacion.circular_id, tipo_a_id: 1} "></select>
I did:
dump($request->detalle);
and I get [object Object] here the image: