fix
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package logic
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fusenapi/model/gmodel"
|
||||
"fusenapi/server/map-library/internal/svc"
|
||||
"fusenapi/server/map-library/internal/types"
|
||||
@@ -60,6 +59,7 @@ func (l *GetMapLibraryListLogic) GetMapLibraryList(userinfo *auth.UserInfo) (res
|
||||
data := types.GetMapLibraryListRsp{
|
||||
Mid: v.Id,
|
||||
Ctime: time.Unix(*v.Ctime, 0).Format("2006-01-02 15:04:05"),
|
||||
Info: *v.Info,
|
||||
}
|
||||
//tag拼装
|
||||
if tagIndex, ok := mapTag[*v.TagId]; ok {
|
||||
@@ -68,13 +68,6 @@ func (l *GetMapLibraryListLogic) GetMapLibraryList(userinfo *auth.UserInfo) (res
|
||||
Title: *templateTagList[tagIndex].Title,
|
||||
}
|
||||
}
|
||||
//解析info
|
||||
var info types.MapLibraryListInfo
|
||||
if err = json.Unmarshal([]byte(*v.Info), &info); err != nil {
|
||||
logx.Error(err)
|
||||
return resp.SetStatusWithMessage(basic.CodeServiceErr, "json parse info err")
|
||||
}
|
||||
data.Info = info
|
||||
list = append(list, data)
|
||||
}
|
||||
return resp.SetStatusWithMessage(basic.CodeOK, "success", list)
|
||||
|
||||
Reference in New Issue
Block a user