caipin 4 年之前
父节点
当前提交
3f0e5a4a85
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      services/tree_service.go

+ 1 - 0
services/tree_service.go

@@ -159,6 +159,7 @@ func (s *treeService) GetAllContract(projectId int, account *models.CmProjectAcc
 	folder.Name = "root"
 	folder.ParentId = parentId
 	folder.Isfolder = 1
+	folder.Children = make([]*viewmodels.FolderContract, 0)
 	folderlist = append(folderlist, folder)
 	// 加入数据
 	for _, data := range datalist {