新增猜你喜欢列表接口111
This commit is contained in:
parent
e77d7b18b8
commit
3a7df99b5e
@ -2,7 +2,6 @@ package service
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"gorm.io/gorm"
|
||||
"hepa-calc-api/api/dao"
|
||||
"hepa-calc-api/api/model"
|
||||
@ -50,7 +49,6 @@ func (r *QuestionService) GetGuessUserLIkeList(userId int64) (m []*model.Questio
|
||||
|
||||
var questions []*model.Question
|
||||
|
||||
fmt.Println(userId)
|
||||
if userId != 0 {
|
||||
maps := make(map[string]interface{})
|
||||
maps["user_id"] = userId
|
||||
@ -61,8 +59,8 @@ func (r *QuestionService) GetGuessUserLIkeList(userId int64) (m []*model.Questio
|
||||
|
||||
// 参与过
|
||||
if len(orderSingles) > 0 {
|
||||
for i, single := range orderSingles {
|
||||
questions[i] = single.Question
|
||||
for _, single := range orderSingles {
|
||||
questions = append(questions, single.Question)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user