-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(seafile): improve features, support access to encrypted library,…
… etc (#6160)
- Loading branch information
Showing
4 changed files
with
234 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,44 @@ | ||
package seafile | ||
|
||
import "time" | ||
|
||
type AuthTokenResp struct { | ||
Token string `json:"token"` | ||
} | ||
|
||
type RepoDirItemResp struct { | ||
type RepoItemResp struct { | ||
Id string `json:"id"` | ||
Type string `json:"type"` // dir, file | ||
Type string `json:"type"` // repo, dir, file | ||
Name string `json:"name"` | ||
Size int64 `json:"size"` | ||
Modified int64 `json:"mtime"` | ||
Permission string `json:"permission"` | ||
} | ||
|
||
type LibraryItemResp struct { | ||
RepoItemResp | ||
OwnerContactEmail string `json:"owner_contact_email"` | ||
OwnerName string `json:"owner_name"` | ||
Owner string `json:"owner"` | ||
ModifierEmail string `json:"modifier_email"` | ||
ModifierContactEmail string `json:"modifier_contact_email"` | ||
ModifierName string `json:"modifier_name"` | ||
Virtual bool `json:"virtual"` | ||
MtimeRelative string `json:"mtime_relative"` | ||
Encrypted bool `json:"encrypted"` | ||
Version int `json:"version"` | ||
HeadCommitId string `json:"head_commit_id"` | ||
Root string `json:"root"` | ||
Salt string `json:"salt"` | ||
SizeFormatted string `json:"size_formatted"` | ||
} | ||
|
||
type RepoDirItemResp struct { | ||
RepoItemResp | ||
} | ||
|
||
type LibraryInfo struct { | ||
LibraryItemResp | ||
decryptedTime time.Time | ||
decryptedSuccess bool | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters