From e1456c546398883655ed1ca8c161c942a3954d62 Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Tue, 6 Aug 2019 10:40:07 +0200 Subject: buildmaster/blacklist.php: remove redundantly shown reasons --- buildmaster/blacklist.php | 40 +++++++++++++++++++++++++++------------- 1 file changed, 27 insertions(+), 13 deletions(-) (limited to 'buildmaster') diff --git a/buildmaster/blacklist.php b/buildmaster/blacklist.php index 24247e8..b76ec88 100644 --- a/buildmaster/blacklist.php +++ b/buildmaster/blacklist.php @@ -4,16 +4,30 @@ require_once "../init.php"; require_once BASE . "/lib/mysql.php"; $result = mysql_run_query( - "SELECT DISTINCT" . - " GROUP_CONCAT(`architectures`.`name`) AS `architectures`," . - "`package_sources`.`pkgbase`," . - "`build_assignments`.`is_black_listed` " . - "FROM `build_assignments` " . - mysql_join_build_assignments_architectures() . - mysql_join_build_assignments_package_sources() . - "WHERE `build_assignments`.`is_black_listed` IS NOT NULL " . - "GROUP BY CONCAT(to_base64(`package_sources`.`pkgbase`),\" - \",to_base64(`build_assignments`.`is_black_listed`)) " . - "ORDER BY `package_sources`.`pkgbase`" + 'SELECT DISTINCT' . + ' GROUP_CONCAT(`q`.`arch`) AS `archs`,' . + '`q`.`pkgbases`,' . + '`q`.`reason`' . + ' FROM (' . + 'SELECT DISTINCT' . + ' `q`.`arch`,' . + 'GROUP_CONCAT(`q`.`pkgbase`) AS `pkgbases`,' . + '`q`.`reason`' . + ' FROM (' . + 'SELECT DISTINCT' . + ' `architectures`.`name` AS `arch`,' . + '`package_sources`.`pkgbase`,' . + '`build_assignments`.`is_black_listed` AS `reason`' . + ' FROM `build_assignments`' . + mysql_join_build_assignments_architectures() . + mysql_join_build_assignments_package_sources() . + 'WHERE `build_assignments`.`is_black_listed` IS NOT NULL' . + ' ORDER BY `package_sources`.`pkgbase`' . + ') AS `q`' . + ' GROUP BY CONCAT(to_base64(`q`.`arch`)," - ",to_base64(`q`.`reason`))' . + ' ORDER BY `q`.`arch`' . + ') AS `q`' . + ' GROUP BY CONCAT(to_base64(`q`.`pkgbases`)," - ",to_base64(`q`.`reason`))' ); ?> @@ -36,10 +50,10 @@ if ($result -> num_rows > 0) { while($row = $result->fetch_assoc()) { print " \n"; print " "; - print $row["architectures"]; + print $row['archs']; print "\n"; print " "; - print $row["pkgbase"]; + print $row['pkgbases']; print "\n"; print " "; print preg_replace( @@ -51,7 +65,7 @@ if ($result -> num_rows > 0) { "$0", "$0" ), - $row["is_black_listed"] + $row['reason'] ); print "\n"; print " \n"; -- cgit v1.2.3-70-g09d2