From 601871c699299ebfad8252ac74fd6ac7fc2a32b1 Mon Sep 17 00:00:00 2001 From: Tomas Kopecek Date: Dec 07 2017 19:47:09 +0000 Subject: show components for all archives Related: https://pagure.io/koji/issue/545 --- diff --git a/www/kojiweb/archiveinfo.chtml b/www/kojiweb/archiveinfo.chtml index ee2d3f4..a99628c 100644 --- a/www/kojiweb/archiveinfo.chtml +++ b/www/kojiweb/archiveinfo.chtml @@ -148,9 +148,9 @@ #end if - #if 'rootid' in $archive and $archive.rootid + #if $show_components - Installed RPMs + Components #end if diff --git a/www/kojiweb/index.py b/www/kojiweb/index.py index 56dfd3e..f2c9564 100644 --- a/www/kojiweb/index.py +++ b/www/kojiweb/index.py @@ -1432,6 +1432,8 @@ def archiveinfo(environ, archiveID, fileOrder='name', fileStart=None, buildrootO values['wininfo'] = wininfo values['builtInRoot'] = builtInRoot values['buildroots'] = buildroots + values['show_components'] = archive.get('rootid', False) or \ + server.listRPMs(imageID=archive['id'], queryOpts={'limit':1}) return _genHTML(environ, 'archiveinfo.chtml')