feat: linux文件排序

This commit is contained in:
meilin.huang
2022-09-26 18:08:12 +08:00
parent cfb7fd5b29
commit 2db4c20dd3
65 changed files with 76 additions and 65 deletions

View File

@@ -14,6 +14,7 @@ import (
"mayfly-go/pkg/ginx"
"mayfly-go/pkg/utils"
"mayfly-go/pkg/ws"
"sort"
"strconv"
"strings"
@@ -124,6 +125,7 @@ func (m *MachineFile) GetDirEntry(rc *ctx.ReqCtx) {
ModTime: fi.ModTime().Format("2006-01-02 15:04:05"),
})
}
sort.Sort(vo.MachineFileInfos(fisVO))
rc.ResData = fisVO
rc.ReqParam = fmt.Sprintf("path: %s", readPath)
}