我可以捕获以JSON格式发送的数据,但是当我通过表单数据发送数据时,其输出如下
{
"status": "error",
"status_code": 422,
"message": "Fields Validation Failed.",
"data": {
"email": [
"The email field is required."
],
"password": [
"The password field is required."
]
}
}
答案 0 :(得分:1)
您需要将字段放在“正文”中,并将字段的值放在“值”中。