From 5c54a2cdcc83b52afa19dffb7d8051b5a99ac690 Mon Sep 17 00:00:00 2001 From: bicijinlian Date: Fri, 18 Dec 2020 13:36:21 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SwaggerStudy/Controllers/StudentController.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/SwaggerStudy/Controllers/StudentController.cs b/SwaggerStudy/Controllers/StudentController.cs index b03b948..4482833 100644 --- a/SwaggerStudy/Controllers/StudentController.cs +++ b/SwaggerStudy/Controllers/StudentController.cs @@ -113,7 +113,7 @@ namespace SwaggerStudy.Controllers return await Task.FromResult(Ok(apiResult)); } - [HttpGet] + [HttpPost] public IActionResult Add(StudentVModel vm) { var apiResult = new ResultBase() @@ -146,7 +146,7 @@ namespace SwaggerStudy.Controllers return Ok(apiResult); } - [HttpGet] + [HttpPost] [ActionName("AddAsync")] public async Task AddAsync(StudentVModel vm) { @@ -180,7 +180,7 @@ namespace SwaggerStudy.Controllers return await Task.FromResult(new JsonResult(apiResult)); } - [HttpGet] + [HttpPost] public IActionResult Update(StudentVModel vm) { var apiResult = new ResultBase() @@ -213,7 +213,7 @@ namespace SwaggerStudy.Controllers return Ok(apiResult); } - [HttpGet] + [HttpPost] [ActionName("UpdateAsync")] public async Task UpdateAsync(StudentVModel vm) { @@ -247,7 +247,7 @@ namespace SwaggerStudy.Controllers return await Task.FromResult(new JsonResult(apiResult)); } - [HttpGet] + [HttpPost] public IActionResult Delete(int studentId) { var apiResult = new ResultBase() @@ -273,7 +273,7 @@ namespace SwaggerStudy.Controllers return Ok(apiResult); } - [HttpGet] + [HttpPost] [ActionName("DeleteAsync")] public async Task DeleteAsync(int studentId) {