|
@@ -359,6 +359,20 @@ func GetSpecialTripUserMap(activityIds []int, userId int) (mapUserId map[int]int
|
|
|
return
|
|
|
}
|
|
|
|
|
|
+//获取用户已经报名的活动数量
|
|
|
+func GetSpecialTripUserSchedule(userId int) (total int, err error) {
|
|
|
+ var condition string
|
|
|
+ var pars []interface{}
|
|
|
+
|
|
|
+ condition += ` AND t.user_id = ? AND t.is_cancel = 0 `
|
|
|
+ pars = append(pars, userId)
|
|
|
+ condition += ` AND a.activity_time_end >= ? `
|
|
|
+ pars = append(pars, time.Now())
|
|
|
+ condition += ` AND is_valid = 1 `
|
|
|
+ total, err = models.GetActivitySpecialTripCountByActivitySpecial(condition, pars)
|
|
|
+ return
|
|
|
+}
|
|
|
+
|
|
|
//GetActivitySpecialList 获取专项调研列表
|
|
|
func GetActivitySpecialList(user *models.WxUserItem, currentIndex, pageSize int, keywords string) (list []*models.CygxActivitySpecialDetail, total int, err error) {
|
|
|
listConfirm, totalConfirm, e := GetActivityLabelSpecialConfirmList(user, (currentIndex-1)*pageSize, pageSize, 4, keywords)
|