增加文章、商品列表修改排序功能
This commit is contained in:
@@ -691,6 +691,26 @@ namespace COMCMS.Web.Areas.AdminCP.Controllers
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 修改文章排序
|
||||
[HttpPost]
|
||||
[MyAuthorize("edit", "article", "JSON")]
|
||||
public IActionResult DoEditArticleSequence(int id, int rank)
|
||||
{
|
||||
Article entity = Article.Find(Article._.Id == id);
|
||||
if (entity == null)
|
||||
{
|
||||
tip.Message = "系统找不到本记录";
|
||||
return Json(tip);
|
||||
}
|
||||
entity.Sequence = rank;
|
||||
entity.Update();
|
||||
Admin.WriteLogActions($"修改文章排序(id:{id},排序:{rank});");
|
||||
tip.Message = "修改排序成功!";
|
||||
tip.Status = JsonTip.SUCCESS;
|
||||
return Json(tip);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 迁移文章
|
||||
[HttpGet]
|
||||
[MyAuthorize("batch", "article")]
|
||||
|
||||
Reference in New Issue
Block a user