Add the builds tab
This commit is contained in:
parent
347bf31f2d
commit
333e0acd6d
25 changed files with 668 additions and 60 deletions
|
@ -2084,11 +2084,14 @@ def get_repository_build(build_uuid):
|
|||
|
||||
|
||||
def list_repository_builds(namespace_name, repository_name, limit,
|
||||
include_inactive=True):
|
||||
include_inactive=True, since=None):
|
||||
query = (_get_build_base_query()
|
||||
.where(Repository.name == repository_name, Namespace.username == namespace_name)
|
||||
.limit(limit))
|
||||
|
||||
if since is not None:
|
||||
query = query.where(RepositoryBuild.started >= since)
|
||||
|
||||
if not include_inactive:
|
||||
query = query.where(RepositoryBuild.phase != 'error',
|
||||
RepositoryBuild.phase != 'complete')
|
||||
|
|
Reference in a new issue