🎨 改进移动文档路径过滤

This commit is contained in:
Liang Ding 2022-11-05 22:59:24 +08:00
parent 1708fb091a
commit 538b0b36a9
No known key found for this signature in database
GPG key ID: 136F30F901A2231D
2 changed files with 18 additions and 2 deletions

View file

@ -1012,7 +1012,11 @@ func MoveDocs(fromPaths []string, toBoxID, toPath string) (err error) {
return
}
fromPaths = util.FilterSelfChildDocs(fromPaths)
fromPaths = util.FilterMoveDocFromPaths(fromPaths, toPath)
if 1 > len(fromPaths) {
return
}
pathsBoxes := getBoxesByPaths(fromPaths)
// 检查路径深度是否超过限制
@ -1024,7 +1028,7 @@ func MoveDocs(fromPaths []string, toBoxID, toPath string) (err error) {
}
}
needShowProgress := 32 < len(fromPaths)
needShowProgress := 16 < len(fromPaths)
if needShowProgress {
util.PushEndlessProgress(Conf.Language(116))
}