feat: add root prefix before operate

This commit is contained in:
Noah Hsu
2022-06-10 20:20:45 +08:00
parent 354dee67dc
commit cd7e9974df
9 changed files with 49 additions and 11 deletions

View File

@ -25,3 +25,15 @@ type Items struct {
Main []Item `json:"main"`
Additional []Item `json:"additional"`
}
type IRootFolderPath interface {
GetRootFolder() string
}
type RootFolderPath struct {
RootFolder string `json:"root_folder" help:"root folder path" default:"/"`
}
func (r RootFolderPath) GetRootFolder() string {
return r.RootFolder
}