From 48166c2411dda06d5f20bce532ef8c37d325451d Mon Sep 17 00:00:00 2001 From: wanggang <76527413@qq.com> Date: Mon, 19 Apr 2021 23:11:28 +0800 Subject: [PATCH] update Former-commit-id: 7718d0dbda32f7d2510c5c83ab74f1ca91c82a53 Former-commit-id: b3fcf013860548560b237c6c53ecec4ffcd179ce --- projects/Infrastructure/Web/Mvc/CrudController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/Infrastructure/Web/Mvc/CrudController.cs b/projects/Infrastructure/Web/Mvc/CrudController.cs index e7bcea4b..2605744c 100644 --- a/projects/Infrastructure/Web/Mvc/CrudController.cs +++ b/projects/Infrastructure/Web/Mvc/CrudController.cs @@ -236,8 +236,8 @@ namespace Infrastructure.Web.Mvc var query = this.Repo.Table(); var entity = query.FirstOrDefault(o => o.Id == id); this.Repo.Delete(entity); + this.Repo.SaveChanges(); } - this.Repo.SaveChanges(); this.AfterDelete(list); return Success(); }