作者 yangfu

app files sort by name

... ... @@ -6,6 +6,7 @@ import (
"gitlab.fjmaimaimai.com/allied-creation/character-library-metadata-bastion/pkg/infrastructure/api/authlib"
"gitlab.fjmaimaimai.com/allied-creation/character-library-metadata-bastion/pkg/infrastructure/api/bytelib"
"path/filepath"
"sort"
"strings"
"time"
... ... @@ -311,6 +312,9 @@ func (fileService *FileService) SearchAppFile(ctx *domain.Context, listFileQuery
files = append(files, file)
}
}
sort.SliceStable(files, func(i, j int) bool {
return files[i].Name < files[j].Name
})
apps = append(apps, &dto.AppDto{
AppId: app.AppId,
AppKey: app.AppKey,
... ...