diff --git a/CoreCms.Net.Uni-App/CoreShop/pages/article/list/list.vue b/CoreCms.Net.Uni-App/CoreShop/pages/article/list/list.vue index abc3896d..b3d30d8f 100644 --- a/CoreCms.Net.Uni-App/CoreShop/pages/article/list/list.vue +++ b/CoreCms.Net.Uni-App/CoreShop/pages/article/list/list.vue @@ -18,7 +18,7 @@ - + {{item.title}} diff --git a/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/create.html b/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/create.html index 227adbfd..b9cfd578 100644 --- a/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/create.html +++ b/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/create.html @@ -36,7 +36,7 @@
- +
@@ -63,7 +63,7 @@
- +
diff --git a/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/edit.html b/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/edit.html index 5c2f9638..615d773a 100644 --- a/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/edit.html +++ b/CoreCms.Net.Web.Admin/wwwroot/views/content/article/articles/edit.html @@ -37,7 +37,7 @@
- +
@@ -115,7 +115,7 @@ } }); editor.setData(d.data.model.contentBody); - + //封面图图片上传 $('#upBtncoverImage').click(function () { cropperImg.cropImg({ diff --git a/CoreCms.Net.Web.WebApi/Controllers/ArticleController.cs b/CoreCms.Net.Web.WebApi/Controllers/ArticleController.cs index a2764630..e385f990 100644 --- a/CoreCms.Net.Web.WebApi/Controllers/ArticleController.cs +++ b/CoreCms.Net.Web.WebApi/Controllers/ArticleController.cs @@ -114,12 +114,12 @@ namespace CoreCms.Net.Web.WebApi.Controllers var where = PredicateBuilder.True(); if (entity.id > 0) { - where = where.And(p => p.isDel == false && p.typeId == entity.id); + where = where.And(p => p.isDel == false && p.typeId == entity.id && p.isPub == true); } else { var typeId = articleType.FirstOrDefault()!.id; - where = where.And(p => p.isDel == false && p.typeId == typeId); + where = where.And(p => p.isDel == false && p.typeId == typeId && p.isPub == true); } var list = await _articleServices.QueryPageAsync(where, p => p.createTime, OrderByType.Desc, entity.page, entity.limit); jm.data = new @@ -168,7 +168,7 @@ namespace CoreCms.Net.Web.WebApi.Controllers jm.data = model; return jm; - } + } #endregion } }