Browse Source

no message

xingzai 2 năm trước cách đây
mục cha
commit
cdfb1c24ca
1 tập tin đã thay đổi với 4 bổ sung2 xóa
  1. 4 2
      controllers/activity.go

+ 4 - 2
controllers/activity.go

@@ -81,10 +81,12 @@ func (this *ActivityController) LabelTypeList() {
 		br.ErrMsg = "获取失败,Err:" + err.Error()
 		return
 	}
-	if len(speciaItem.List) == 0 {
+
+	if len(speciaItem.List) > 0 {
+		list = append(list, speciaItem)
+	} else {
 		speciaItem.List = make([]*models.CygxActivityLabelList, 0)
 	}
-	list = append(list, speciaItem)
 
 	resp := new(models.ActivityTypeListHomeResp)
 	resp.List = list