作者 yangfu

修正序列化错误

@@ -340,8 +340,10 @@ func TemplateList(uid, companyId int64, request *protocol.TemplateListRequest) ( @@ -340,8 +340,10 @@ func TemplateList(uid, companyId int64, request *protocol.TemplateListRequest) (
340 // log.Error(err.Error()) 340 // log.Error(err.Error())
341 // return 341 // return
342 //} 342 //}
343 - if e := json.Unmarshal([]byte(temp.VisibleObject), &vObj); e != nil {  
344 - log.Error("%v %v %v", temp.Id, temp.VisibleObject, e.Error()) 343 + if len(temp.VisibleObject) > 0 {
  344 + if e := json.Unmarshal([]byte(temp.VisibleObject), &vObj); e != nil {
  345 + log.Error("%v %v %v", temp.Id, temp.VisibleObject, e.Error())
  346 + }
345 } 347 }
346 tempItem := &protocol.TemplateItem{ 348 tempItem := &protocol.TemplateItem{
347 Id: temp.Id, 349 Id: temp.Id,