mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-03 23:38:49 +01:00
🎨 Improve upload assets tip
This commit is contained in:
parent
876e95ef27
commit
b9f1da33f0
7 changed files with 15 additions and 9 deletions
|
|
@ -509,13 +509,17 @@ func GetAssetAbsPath(relativePath string) (ret string, err error) {
|
|||
return "", errors.New(fmt.Sprintf(Conf.Language(12), relativePath))
|
||||
}
|
||||
|
||||
func UploadAssets2Cloud(rootID string) (err error) {
|
||||
func UploadAssets2Cloud(rootID string) (count int, err error) {
|
||||
if !IsSubscriber() {
|
||||
return
|
||||
}
|
||||
|
||||
sqlAssets := sql.QueryRootBlockAssets(rootID)
|
||||
err = uploadAssets2Cloud(sqlAssets, bizTypeUploadAssets)
|
||||
if nil != err {
|
||||
return
|
||||
}
|
||||
count = len(sqlAssets)
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue