🎨 云端收集箱文档内添加刷新按钮 https://github.com/siyuan-note/siyuan/issues/6306
This commit is contained in:
parent
ef5d7d5755
commit
cd99b9fa9d
1 changed files with 4 additions and 4 deletions
|
@ -357,8 +357,8 @@ func RemoveCloudShorthands(ids []string) (err error) {
|
|||
return
|
||||
}
|
||||
|
||||
func GetCloudShorthand(id string) (result map[string]interface{}, err error) {
|
||||
result = map[string]interface{}{}
|
||||
func GetCloudShorthand(id string) (ret map[string]interface{}, err error) {
|
||||
result := map[string]interface{}{}
|
||||
request := httpclient.NewCloudRequest()
|
||||
resp, err := request.
|
||||
SetResult(&result).
|
||||
|
@ -381,10 +381,10 @@ func GetCloudShorthand(id string) (result map[string]interface{}, err error) {
|
|||
err = errors.New(result["msg"].(string))
|
||||
return
|
||||
}
|
||||
shorthand := result["data"].(map[string]interface{})
|
||||
ret = result["data"].(map[string]interface{})
|
||||
t, _ := strconv.ParseInt(id, 10, 64)
|
||||
hCreated := util.Millisecond2Time(t)
|
||||
shorthand["hCreated"] = hCreated.Format("2006-01-02 15:04")
|
||||
ret["hCreated"] = hCreated.Format("2006-01-02 15:04")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue