mirror of
https://github.com/go-gitea/gitea
synced 2025-09-28 03:28:13 +00:00
Fix filter count
This commit is contained in:
@@ -77,3 +77,7 @@ func FindRuns(ctx context.Context, opts FindRunOptions) (RunList, int64, error)
|
||||
total, err := e.Desc("id").FindAndCount(&runs)
|
||||
return runs, total, err
|
||||
}
|
||||
|
||||
func CountRuns(ctx context.Context, opts FindRunOptions) (int64, error) {
|
||||
return db.GetEngine(ctx).Where(opts.toConds()).Count(new(Run))
|
||||
}
|
||||
|
Reference in New Issue
Block a user