xingzai il y a 2 ans
Parent
commit
fae05bb274
1 fichiers modifiés avec 25 ajouts et 25 suppressions
  1. 25 25
      controllers/activity.go

+ 25 - 25
controllers/activity.go

@@ -2821,31 +2821,31 @@ func (this *ActivityCoAntroller) ActivityListNew() {
 	var activityList []*models.ActivityDetail
 	mapDingActivityId := make(map[int]int)
 	//进行中的活动拍在最上面
-	if keyWord != "" {
-		conditionActivity, err := services.GetActivityonditionList(user, activityTypeId, chartPermissionIds, whichDay, strconv.Itoa(2), label, 0, source, keyWord)
-		if err != nil && err.Error() != utils.ErrNoRow() {
-			br.Msg = "获取失败"
-			br.ErrMsg = "获取活动权限数据失败,Err:" + err.Error()
-			return
-		}
-		if source == 1 {
-			condition += ` AND art.yidong_activity_id = '' `
-		}
-		condition += ` AND art.is_limit_people = 1 AND art.publish_status = 1 ` + conditionActivity
-		condition += ` ORDER BY art.activity_time ASC   `
-		listDing, err := models.GetActivityListAll(condition, pars, uid, startSize, pageSize, playBack)
-		if err != nil && err.Error() != utils.ErrNoRow() {
-			br.Msg = "获取失败"
-			br.ErrMsg = "获取活动权限数据失败,Err:" + err.Error()
-			return
-		}
-		if len(listDing) > 0 {
-			for _, v := range listDing {
-				activityList = append(activityList, v)
-				mapDingActivityId[v.ActivityId] = v.ActivityId
-			}
-		}
-	}
+	//if keyWord != "" {
+	//	conditionActivity, err := services.GetActivityonditionList(user, activityTypeId, chartPermissionIds, whichDay, strconv.Itoa(2), label, 0, source, keyWord)
+	//	if err != nil && err.Error() != utils.ErrNoRow() {
+	//		br.Msg = "获取失败"
+	//		br.ErrMsg = "获取活动权限数据失败,Err:" + err.Error()
+	//		return
+	//	}
+	//	if source == 1 {
+	//		condition += ` AND art.yidong_activity_id = '' `
+	//	}
+	//	condition += ` AND art.is_limit_people = 1 AND art.publish_status = 1 ` + conditionActivity
+	//	condition += ` ORDER BY art.activity_time ASC   `
+	//	listDing, err := models.GetActivityListAll(condition, pars, uid, startSize, pageSize, playBack)
+	//	if err != nil && err.Error() != utils.ErrNoRow() {
+	//		br.Msg = "获取失败"
+	//		br.ErrMsg = "获取活动权限数据失败,Err:" + err.Error()
+	//		return
+	//	}
+	//	if len(listDing) > 0 {
+	//		for _, v := range listDing {
+	//			activityList = append(activityList, v)
+	//			mapDingActivityId[v.ActivityId] = v.ActivityId
+	//		}
+	//	}
+	//}
 	condition = ""
 	//活动可见限制
 	conditionActivity, err := services.GetActivityonditionList(user, activityTypeId, chartPermissionIds, whichDay, activeState, label, 0, source, keyWord, playBack)