作者 tangxvhui

补充搜索条件

@@ -121,7 +121,7 @@ func (repository *ArticleDraftRepository) Find(ctx context.Context, conn transac @@ -121,7 +121,7 @@ func (repository *ArticleDraftRepository) Find(ctx context.Context, conn transac
121 queryFunc := func() (interface{}, error) { 121 queryFunc := func() (interface{}, error) {
122 tx = tx.Model(&ms).Order("id desc") 122 tx = tx.Model(&ms).Order("id desc")
123 if v, ok := queryOptions["authorId"]; ok { 123 if v, ok := queryOptions["authorId"]; ok {
124 - tx = tx.Where("author_id", v) 124 + tx = tx.Where("author_id=?", v)
125 } 125 }
126 126
127 if total, tx = transaction.PaginationAndCount(ctx, tx, queryOptions, &ms); tx.Error != nil { 127 if total, tx = transaction.PaginationAndCount(ctx, tx, queryOptions, &ms); tx.Error != nil {