作者 tangxvhui

Merge branch 'dev' into test

... ... @@ -120,6 +120,10 @@ func (repository *ArticleDraftRepository) Find(ctx context.Context, conn transac
)
queryFunc := func() (interface{}, error) {
tx = tx.Model(&ms).Order("id desc")
if v, ok := queryOptions["authorId"]; ok {
tx = tx.Where("author_id=?", v)
}
if total, tx = transaction.PaginationAndCount(ctx, tx, queryOptions, &ms); tx.Error != nil {
return dms, tx.Error
}
... ...