handles

package
v3.39.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 17, 2024 License: AGPL-3.0 Imports: 53 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddOfflineDownload added in v3.29.0

func AddOfflineDownload(c *gin.Context)

func BeginAuthnLogin added in v3.26.0

func BeginAuthnLogin(c *gin.Context)

func BeginAuthnRegistration added in v3.26.0

func BeginAuthnRegistration(c *gin.Context)

func BuildIndex added in v3.6.0

func BuildIndex(c *gin.Context)

func Cancel2FAById

func Cancel2FAById(c *gin.Context)

func ClearIndex added in v3.7.1

func ClearIndex(c *gin.Context)

func CreateMeta

func CreateMeta(c *gin.Context)

func CreateStorage

func CreateStorage(c *gin.Context)

func CreateUser

func CreateUser(c *gin.Context)

func CurrentUser

func CurrentUser(c *gin.Context)

CurrentUser get current user by token if token is empty, return guest user

func DelUserCache added in v3.25.0

func DelUserCache(c *gin.Context)

func DeleteAuthnLogin added in v3.26.0

func DeleteAuthnLogin(c *gin.Context)

func DeleteMeta

func DeleteMeta(c *gin.Context)

func DeleteSetting

func DeleteSetting(c *gin.Context)

func DeleteStorage

func DeleteStorage(c *gin.Context)

func DeleteUser

func DeleteUser(c *gin.Context)

func DisableStorage

func DisableStorage(c *gin.Context)

func Down

func Down(c *gin.Context)

func EnableStorage

func EnableStorage(c *gin.Context)

func Favicon

func Favicon(c *gin.Context)

func FinishAuthnLogin added in v3.26.0

func FinishAuthnLogin(c *gin.Context)

func FinishAuthnRegistration added in v3.26.0

func FinishAuthnRegistration(c *gin.Context)

func FsBatchRename added in v3.20.0

func FsBatchRename(c *gin.Context)

func FsCopy

func FsCopy(c *gin.Context)

func FsDirs

func FsDirs(c *gin.Context)

func FsForm

func FsForm(c *gin.Context)

func FsGet

func FsGet(c *gin.Context)

func FsList

func FsList(c *gin.Context)

func FsMkdir

func FsMkdir(c *gin.Context)

func FsMove

func FsMove(c *gin.Context)

func FsOther

func FsOther(c *gin.Context)

func FsRecursiveMove added in v3.14.0

func FsRecursiveMove(c *gin.Context)

func FsRegexRename added in v3.14.0

func FsRegexRename(c *gin.Context)

func FsRemove

func FsRemove(c *gin.Context)

func FsRemoveEmptyDirectory added in v3.16.0

func FsRemoveEmptyDirectory(c *gin.Context)

func FsRename

func FsRename(c *gin.Context)

func FsStream

func FsStream(c *gin.Context)

func Generate2FA

func Generate2FA(c *gin.Context)

func GetAuthnCredentials added in v3.26.0

func GetAuthnCredentials(c *gin.Context)

func GetDriverInfo

func GetDriverInfo(c *gin.Context)

func GetMeta

func GetMeta(c *gin.Context)

func GetOIDCClient added in v3.19.0

func GetOIDCClient(c *gin.Context) (*oauth2.Config, error)

func GetProgress added in v3.6.0

func GetProgress(c *gin.Context)

func GetSetting

func GetSetting(c *gin.Context)

func GetStorage

func GetStorage(c *gin.Context)

func GetUser

func GetUser(c *gin.Context)
func Link(c *gin.Context)

Link return real link, just for proxy program, it may contain cookie, so just allowed for admin

func ListDriverInfo

func ListDriverInfo(c *gin.Context)

func ListDriverNames

func ListDriverNames(c *gin.Context)

func ListMetas

func ListMetas(c *gin.Context)

func ListSettings

func ListSettings(c *gin.Context)

func ListStorages

func ListStorages(c *gin.Context)

func ListUsers

func ListUsers(c *gin.Context)

func LoadAllStorages added in v3.7.1

func LoadAllStorages(c *gin.Context)

func LogOut added in v3.37.0

func LogOut(c *gin.Context)

func Login

func Login(c *gin.Context)

Login Deprecated

func LoginHash added in v3.25.0

func LoginHash(c *gin.Context)

LoginHash login with password hashed by sha256

func LoginLdap added in v3.30.0

func LoginLdap(c *gin.Context)

func OIDCLoginCallback added in v3.19.0

func OIDCLoginCallback(c *gin.Context)

func OfflineDownloadTools added in v3.29.0

func OfflineDownloadTools(c *gin.Context)

func Plist

func Plist(c *gin.Context)

func Proxy

func Proxy(c *gin.Context)

func PublicSettings

func PublicSettings(c *gin.Context)

func ResetToken

func ResetToken(c *gin.Context)

func Robots added in v3.17.0

func Robots(c *gin.Context)

func SSOLoginCallback added in v3.13.0

func SSOLoginCallback(c *gin.Context)

func SSOLoginRedirect added in v3.13.0

func SSOLoginRedirect(c *gin.Context)

func SaveSettings

func SaveSettings(c *gin.Context)
func Search(c *gin.Context)

func SetAria2

func SetAria2(c *gin.Context)

func SetQbittorrent added in v3.11.0

func SetQbittorrent(c *gin.Context)

func SetTransmission added in v3.38.0

func SetTransmission(c *gin.Context)

func SetupTaskRoute added in v3.11.0

func SetupTaskRoute(g *gin.RouterGroup)

func StopIndex added in v3.6.0

func StopIndex(c *gin.Context)

func UpdateCurrent

func UpdateCurrent(c *gin.Context)

func UpdateIndex added in v3.7.1

func UpdateIndex(c *gin.Context)

func UpdateMeta

func UpdateMeta(c *gin.Context)

func UpdateStorage

func UpdateStorage(c *gin.Context)

func UpdateUser

func UpdateUser(c *gin.Context)

func Verify2FA

func Verify2FA(c *gin.Context)

Types

type AddOfflineDownloadReq added in v3.29.0

type AddOfflineDownloadReq struct {
	Urls         []string `json:"urls"`
	Path         string   `json:"path"`
	Tool         string   `json:"tool"`
	DeletePolicy string   `json:"delete_policy"`
}

type BatchRenameReq added in v3.20.0

type BatchRenameReq struct {
	SrcDir        string `json:"src_dir"`
	RenameObjects []struct {
		SrcName string `json:"src_name"`
		NewName string `json:"new_name"`
	} `json:"rename_objects"`
}

type DirReq

type DirReq struct {
	Path      string `json:"path" form:"path"`
	Password  string `json:"password" form:"password"`
	ForceRoot bool   `json:"force_root" form:"force_root"`
}

type DirResp

type DirResp struct {
	Name     string    `json:"name"`
	Modified time.Time `json:"modified"`
}

type FsGetReq

type FsGetReq struct {
	Path     string `json:"path" form:"path"`
	Password string `json:"password" form:"password"`
}

type FsGetResp

type FsGetResp struct {
	ObjResp
	RawURL   string    `json:"raw_url"`
	Readme   string    `json:"readme"`
	Header   string    `json:"header"`
	Provider string    `json:"provider"`
	Related  []ObjResp `json:"related"`
}

type FsListResp

type FsListResp struct {
	Content  []ObjResp `json:"content"`
	Total    int64     `json:"total"`
	Readme   string    `json:"readme"`
	Header   string    `json:"header"`
	Write    bool      `json:"write"`
	Provider string    `json:"provider"`
}

type FsOtherReq

type FsOtherReq struct {
	model.FsOtherArgs
	Password string `json:"password" form:"password"`
}

type ListReq

type ListReq struct {
	model.PageReq
	Path     string `json:"path" form:"path"`
	Password string `json:"password" form:"password"`
	Refresh  bool   `json:"refresh"`
}

type LoginReq

type LoginReq struct {
	Username string `json:"username" binding:"required"`
	Password string `json:"password"`
	OtpCode  string `json:"otp_code"`
}

type MkdirOrLinkReq

type MkdirOrLinkReq struct {
	Path string `json:"path" form:"path"`
}

type MoveCopyReq

type MoveCopyReq struct {
	SrcDir string   `json:"src_dir"`
	DstDir string   `json:"dst_dir"`
	Names  []string `json:"names"`
}

type ObjResp

type ObjResp struct {
	Name        string                     `json:"name"`
	Size        int64                      `json:"size"`
	IsDir       bool                       `json:"is_dir"`
	Modified    time.Time                  `json:"modified"`
	Created     time.Time                  `json:"created"`
	Sign        string                     `json:"sign"`
	Thumb       string                     `json:"thumb"`
	Type        int                        `json:"type"`
	HashInfoStr string                     `json:"hashinfo"`
	HashInfo    map[*utils.HashType]string `json:"hash_info"`
}

type RecursiveMoveReq added in v3.14.0

type RecursiveMoveReq struct {
	SrcDir string `json:"src_dir"`
	DstDir string `json:"dst_dir"`
}

type RegexRenameReq added in v3.14.0

type RegexRenameReq struct {
	SrcDir       string `json:"src_dir"`
	SrcNameRegex string `json:"src_name_regex"`
	NewNameRegex string `json:"new_name_regex"`
}

type RemoveEmptyDirectoryReq added in v3.16.0

type RemoveEmptyDirectoryReq struct {
	SrcDir string `json:"src_dir"`
}

type RemoveReq

type RemoveReq struct {
	Dir   string   `json:"dir"`
	Names []string `json:"names"`
}

type RenameReq

type RenameReq struct {
	Path string `json:"path"`
	Name string `json:"name"`
}

type SearchReq added in v3.7.1

type SearchReq struct {
	model.SearchReq
	Password string `json:"password"`
}

type SearchResp added in v3.6.0

type SearchResp struct {
	model.SearchNode
	Type int `json:"type"`
}

type SetAria2Req

type SetAria2Req struct {
	Uri    string `json:"uri" form:"uri"`
	Secret string `json:"secret" form:"secret"`
}

type SetQbittorrentReq added in v3.11.0

type SetQbittorrentReq struct {
	Url      string `json:"url" form:"url"`
	Seedtime string `json:"seedtime" form:"seedtime"`
}

type SetTransmissionReq added in v3.38.0

type SetTransmissionReq struct {
	Uri      string `json:"uri" form:"uri"`
	Seedtime string `json:"seedtime" form:"seedtime"`
}

type TaskInfo

type TaskInfo struct {
	ID          string      `json:"id"`
	Name        string      `json:"name"`
	Creator     string      `json:"creator"`
	CreatorRole int         `json:"creator_role"`
	State       tache.State `json:"state"`
	Status      string      `json:"status"`
	Progress    float64     `json:"progress"`
	Error       string      `json:"error"`
}

type UpdateIndexReq added in v3.9.0

type UpdateIndexReq struct {
	Paths    []string `json:"paths"`
	MaxDepth int      `json:"max_depth"`
}

type UserResp

type UserResp struct {
	model.User
	Otp bool `json:"otp"`
}

type Verify2FAReq

type Verify2FAReq struct {
	Code   string `json:"code" binding:"required"`
	Secret string `json:"secret" binding:"required"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL