From 402f86a57f965f8dc21dc4312281c434263366a9 Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Tue, 19 Feb 2019 13:56:42 +0100 Subject: packages/differences.php now functional --- lib/style.php | 42 ++++++++++++++---- packages/differences.php | 111 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 144 insertions(+), 9 deletions(-) create mode 100644 packages/differences.php diff --git a/lib/style.php b/lib/style.php index ee40d10..547e350 100644 --- a/lib/style.php +++ b/lib/style.php @@ -98,15 +98,10 @@ $difflist_sorts = array( "label" => "i686 Version", "mysql" => "`i686_version`" ), - "i486_repo" => array( - "title" => "i486 repository", - "label" => "i486 Repository", - "mysql" => "`i486_repo`" - ), - "i686_repo" => array( - "title" => "i686 repository", - "label" => "i686 Repository", - "mysql" => "`i686_repo`" + "repo" => array( + "title" => "repository", + "label" => "Repository", + "mysql" => "`repo`" ), "i486_last_moved" => array( "title" => "i486 last updated", @@ -120,6 +115,35 @@ $difflist_sorts = array( ) ); +$difflist_print_columns = array( + 'name' => array('$pkgname'), + 'i486_version' => array( + '"', + '$i486_font_pre', + '$i486_version', + '$i486_font_post', + '"' + ), + 'i686_version' => array( + '"', + '$i686_font_pre', + '$i686_version', + '$i686_font_post', + '"' + ), + 'repository' => array('$repository'), + 'i486_move_date' => array('$i486_move_date'), + 'i686_move_date' => array('$i686_move_date') +); + $grouplist_sorts = array( "arch" => array( "title" => "architecture", diff --git a/packages/differences.php b/packages/differences.php new file mode 100644 index 0000000..e861a63 --- /dev/null +++ b/packages/differences.php @@ -0,0 +1,111 @@ + fetch_assoc()) { + $row['i486_move_date'] = substr($row['i486_last_moved'], 0, 10); + $row['i686_move_date'] = substr($row['i686_last_moved'], 0, 10); + if ($row['i486_is_oldest']) { + $row['i486_font_pre'] = ''; + $row['i486_font_post'] = ''; + $row['i686_font_pre'] = ''; + $row['i686_font_post'] = ''; + } else { + $row['i486_font_pre'] = ''; + $row['i486_font_post'] = ''; + $row['i686_font_pre'] = ''; + $row['i686_font_post'] = ''; + } + $differences[] = $row; +} + +print_header('Package Differences Reports'); +print "
\n"; +print "

Architecture Differences Between Packages

\n"; +print_listing($differences, true, 'diff'); +print "
\n"; +print_footer(); -- cgit v1.2.3