123456789101112131415 |
- package yb_activity_voice
- import "hongze/hongze_yb/global"
- // GetVoicesByActivityId 根据活动ID获取录音
- func GetVoicesByActivityId(activityId int) (voices []*YbActivityVoice, err error) {
- err = global.DEFAULT_MYSQL.Table("yb_activity_voice").Where("activity_id", activityId).Scan(&voices).Error
- return
- }
- // GetVoicesByActivityIds 根据活动IDs获取录音
- func GetVoicesByActivityIds(activityIds []int) (voices []*YbActivityVoice, err error) {
- err = global.DEFAULT_MYSQL.Model(YbActivityVoice{}).Where("activity_id IN (?)", activityIds).Scan(&voices).Error
- return
- }
|