Feat: set default view method in file manager

This commit is contained in:
HFO4
2020-01-29 14:25:14 +08:00
parent e2f6dab70c
commit a0c320b964
4 changed files with 35 additions and 23 deletions

View File

@@ -61,7 +61,11 @@ func BuildShareResponse(share *model.Share, unlocked bool) Share {
}
if share.IsDir {
source := share.GetSourceFolder()
resp.Source = &shareSource{
Name: source.Name,
Size: 0,
}
} else {
source := share.GetSourceFile()
resp.Source = &shareSource{