Browse Source

git commit -a -m '后:组织树排序'

dubch 5 years ago
parent
commit
c9f782bf49
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/dashoo.cn/backend/api/controllers/casbin/organize.go

+ 2 - 2
src/dashoo.cn/backend/api/controllers/casbin/organize.go

@@ -62,7 +62,7 @@ func (this *OrganizesController) List() {
 		where = where + " and Id in ( " + ids + " )"
 	}
 	list := make([]organize.Base_Organize, 0)
-	total := svc.GetPagingEntitiesWithSortCode(page.CurrentPage, page.Size, "ParentId, CreateOn desc", &list, where)
+	total := svc.GetPagingEntitiesWithSortCode(page.CurrentPage, page.Size, "ParentId, Id asc", &list, where)
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total
@@ -130,7 +130,7 @@ func (this *OrganizesController) Listbandparentname() {
 		ids := svc.GetAllChildByTopId(parentid, this.User.Id)
 		where = where + " and a.Id in ( " + ids + " )"
 	}
-	total, list := svc.GetListbandparentname(page.CurrentPage, page.Size, "a.ParentId, a.CreateOn desc", where)
+	total, list := svc.GetListbandparentname(page.CurrentPage, page.Size, "a.ParentId, a.Id asc", where)
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total