blob: 1c155972b211411fb7c4e3615caf0f675cc087f2 [file] [log] [blame]
<?php
error_reporting(E_ALL);
ini_set("display_errors", true);
require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/app.class.php");
$App = new App();
$seed_platform = array(435024, 420956, 378644, 384835, 269121, 117746, 378811, 401633, 428664, 375576, 354538, 437353, 436225, 436763, 366708, 373294, 427777, 432498, 394386, 406733, 436755, 118919, 411704, 436236, 438324, 432849, 340889, 435274, 436572, 430403, 397029, 378672, 430128, 398837, 350251, 201589, 432399, 437207, 445600, 429505, 410749, 431032, 401632, 348429, 432785, 436645, 424978, 434102, 392876, 416650, 232171, 401327, 434108, 400578, 435435, 431990, 37478, 421425, 269271, 374132, 391145, 436863, 433809, 436247, 434506, 372523, 435191, 389920, 401835, 445305, 376486, 430205, 320901, 372799, 380663, 366554, 366608, 325937, 375744, 430872, 436499, 330117, 392715, 399659, 410087, 414845, 431894, 423056, 430964, 435161, 414736, 432466, 435655, 435623, 434207, 436788, 366606, 361133, 371934, 388476, 387714, 431218, 405542, 376486, 412013, 414738, 174689, 348560, 434871, 336584, 422720, 432686, 413410, 433789, 436796, 366635, 377448, 388510, 403930, 436115, 433519, 435512, 430051, 413112, 430199, 333742, 334303, 178229, 301687, 365592, 366564, 393454, 402322, 404231, 408309, 366600, 260408, 433723, 435915, 436164, 436183, 420843, 279902, 382625, 437202, 366534, 383832, 412634, 325965, 376862, 436062, 378566, 418661, 431097, 391430, 432463, 435847, 437624, 433215, 416845, 417367, 428297, 365607, 209873, 320727, 345608, 366595, 373011, 378408, 384351, 395455, 398475, 402519, 404727, 408592, 408740, 409678, 413952, 418589, 359778, 153470, 366602, 427647, 401015, 367116, 429793, 431242, 436840, 387579, 421155, 404015, 416761, 389478, 222877, 242246, 275923, 372508, 378861, 397704, 402593, 410624, 191256, 412739, 427623, 431376, 431862, 436448, 432856, 388963, 317207, 374017, 283930, 314463, 331131, 339740, 348331, 350799, 355426, 356457, 364566, 369237, 373007, 391344, 398277, 400217, 401534, 410164, 414611, 414888, 418231, 360468, 368466, 280033, 405859, 385278, 304530, 430126, 433765, 281593, 430306, 436322, 433895);
$seed_webtools = array(271360, 363803, 417137, 419931, 436737, 453700, 459244);
function greatfix__find_bugs($ids, $max) {
global $App;
$list = join(',', $ids);
$seed_bugs = array();
$result = $App->bugzilla_sql("
select distinct
b.bug_id as id, b.short_desc as summary,
pr.name as product, cp.name as component
from bugs as b
join products as pr on b.product_id=pr.id
join components as cp on b.component_id=cp.id
left join keywords as k on b.bug_id=k.bug_id
left join keyworddefs as kd on k.keywordid=kd.id
and kd.name in ('bugday', 'helpwanted')
and kd.name not in ('greatfix', 'greatbug')
where bug_status in ('NEW', 'REOPENED')
and b.bug_id in ($list)
order by if(kd.name='bugday',1,if(kd.name='helpwanted', 2,3))
limit $max");
while ($row = mysql_fetch_assoc($result)) {
$id = $row['id'];
$summary = trim(preg_replace('/\[[^\]]+\]/', '', $row['summary']));
$product = $row['product'];
$component = $row['component'];
$seed_bugs[] = "<li><a href=\"https://bugs.eclipse.org/$id\">$id</a> [$product/$component] $summary";
}
return $seed_bugs;
}
$seed_bugs = greatfix__find_bugs($seed_platform, 10);
$seed_bugs = array_merge($seed_bugs, greatfix__find_bugs($seed_webtools, 5));
if ($seed_bugs) {
shuffle($seed_bugs);
$bug_list = "<ul>" . join("\n", $seed_bugs) . "</ul>";
}
require_once ($_SERVER ['DOCUMENT_ROOT'] . "/eclipse.org-common/system/app.class.php");
require_once ($_SERVER ['DOCUMENT_ROOT'] . "/eclipse.org-common/system/nav.class.php");
require_once ($_SERVER ['DOCUMENT_ROOT'] . "/eclipse.org-common/system/menu.class.php");
$App = new App ();
$Nav = new Nav ();
$Menu = new Menu ();
include ($App->getProjectCommon ());
ob_start ();
$pageKeywords = "";
$pageTitle = "Great Fixes for Mars";
$pageAuthor = "Wayne Beaton";
?>
<?= $bug_list ?>
<?php
$html = ob_get_contents ();
ob_end_clean ();
$App->generatePage ( $theme, $Menu, $Nav, $pageAuthor, $pageKeywords, $pageTitle, $html );
?>