Hello @klasss-pt
I didn't see a save call in your edit part. That is needed to save the changed values in the database.
// $item need to be loaded here
$item->nome = $request->nome;
$item->email = $request->email;
$item->n_ferias_disponiveis = $request->n_ferias_disponiveis;
$item->data_registo = $now;
$item->save();
$ferias= ferias::find(1);
will find the ferias object with id 1. I don't know where you get your id from but you need to place that in the find call.
ps. I have updated your post to add the codeblocks
So put something like
$ferias=ferias::find($item->id);
would it work?
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community