|
@@ -425,6 +425,7 @@ func (n *network) AllProject(in *types.AllprojectReq) (reply *types.Reply) {
|
|
|
list[v.Itype-1].Children = append(list[v.Itype-1].Children, ntc)
|
|
|
}
|
|
|
}
|
|
|
+ parentConvList := &nodeTrees{}
|
|
|
convList := &nodeTrees{}
|
|
|
for _, v := range list {
|
|
|
pm := &nodeTree{
|
|
@@ -549,13 +550,14 @@ func (n *network) AllProject(in *types.AllprojectReq) (reply *types.Reply) {
|
|
|
pm.TYPE = pType
|
|
|
pm.MYTYPE = pMyType
|
|
|
pm.MYID = pMyId
|
|
|
- *convList = append(*convList, pm)
|
|
|
+ *parentConvList = append(*parentConvList, pm)
|
|
|
}
|
|
|
sort.Sort(convList)
|
|
|
+ *parentConvList = append(*parentConvList, *convList...)
|
|
|
reply = &types.Reply{
|
|
|
Data: map[string]interface{}{
|
|
|
"count": count,
|
|
|
- "list": convList,
|
|
|
+ "list": parentConvList,
|
|
|
},
|
|
|
}
|
|
|
return reply
|