Add a history view to the tags page. Next step will add the ability to revert back in time

This commit is contained in:
Joseph Schorr 2015-04-15 15:21:09 -04:00
parent 703f48f194
commit f8c80f7d11
10 changed files with 492 additions and 13 deletions

View file

@ -1762,6 +1762,16 @@ def _tag_alive(query, now_ts=None):
(RepositoryTag.lifetime_end_ts > now_ts))
def list_repository_tag_history(repository, limit=100):
query = (RepositoryTag
.select(RepositoryTag, Image)
.join(Image)
.where(RepositoryTag.repository == repository)
.order_by(RepositoryTag.lifetime_start_ts.desc())
.limit(limit))
return query
def list_repository_tags(namespace_name, repository_name, include_hidden=False,
include_storage=False):