<form asp-action="Delete"> @foreach (var item in Model.Items) { <input type="checkbox" name="chk" value="@item.ID" />}</form>
后台代码:
[HttpPost, ValidateAntiForgeryToken] public async Task<IActionResult> Delete() { return Json(new { success = true }); }
这里如何取得checkbox的值,request吗?