0
public function orgPurokEdit($orgId, $purok, $newPurokName)
{
$updated = Data::where('org_id', $orgId)
->where('purok', $purok)
->update(['purok' => $newPurokName]);
if($updated){
$this->success = true;
}else
{
$this->errors = "Not updated";
}
return response()->json([
'success' => $this->success,
'errors' => $this->errors
]);
}
これはコードですが、データは更新されませんでした。これに何か問題はありますか?助けを前にありがとう。Laravelで更新できませんでした
それは 'true'を返すのか、' updated'ないですか? – Jackowski
列を塗りつぶし可能な配列に追加しましたか? –
これはresponse.success = falseを返す – Jen143