This commit is contained in:
Liang Ding 2022-07-15 11:15:02 +08:00
parent f39750e393
commit 14c023477c
No known key found for this signature in database
GPG key ID: 136F30F901A2231D
2 changed files with 18 additions and 2 deletions

View file

@ -39,7 +39,13 @@ func renameAsset(c *gin.Context) {
oldPath := arg["oldPath"].(string)
newName := arg["newName"].(string)
model.RenameAsset(oldPath, newName)
err := model.RenameAsset(oldPath, newName)
if nil != err {
ret.Code = -1
ret.Msg = err.Error()
ret.Data = map[string]interface{}{"closeTimeout": 5000}
return
}
}
func getDocImageAssets(c *gin.Context) {