logo search
This commit is contained in:
parent
d9d16753c0
commit
c136231742
|
@ -15,7 +15,7 @@ func (p *FsPreprocessLogoModel) PreLogoSearchSuggestions(ctx context.Context, zi
|
|||
for i, v := range keywords {
|
||||
keywords[i] = "+" + v + v
|
||||
}
|
||||
sqlstr := fmt.Sprintf("SELECT * FROM fs_preprocess_logo WHERE MATCH(restaurant_name) AGAINST('?' IN BOOLEAN MODE) limit %d;", count)
|
||||
sqlstr := fmt.Sprintf("SELECT * FROM fs_preprocess_logo WHERE MATCH(restaurant_name) AGAINST(? IN BOOLEAN MODE) limit %d;", count)
|
||||
|
||||
tx := p.db.WithContext(ctx).Model(&FsPreprocessLogo{}).Raw(sqlstr, strings.Join(keywords, " "))
|
||||
err = tx.Scan(&resp).Error
|
||||
|
|
Loading…
Reference in New Issue
Block a user