getCategoryPath(),$appId, $versionId);
echo html_frame_start("",'98%','',2);
echo "
Category: $catFullPath
\n";
echo html_frame_end();
}
/* display the SUB apps that belong to this app */
function display_bundle($appId)
{
$result = query_appdb("SELECT appFamily.appId, appName, description FROM appBundle, appFamily ".
"WHERE bundleId = $appId AND appBundle.appId = appFamily.appId");
if(!$result || mysql_num_rows($result) == 0)
{
// do nothing
return;
}
echo html_frame_start("","98%","",0);
echo "
\n\n";
echo "\n";
echo " | Application Name | \n";
echo " Description | \n";
echo "
\n\n";
$c = 0;
while($ob = mysql_fetch_object($result))
{
//set row color
$bgcolor = (($c % 2) ? "color0" : "color1");
//format desc
$desc = substr(stripslashes($ob->description),0,50);
if(strlen($desc) == 50)
$desc .= " ...";
//display row
echo "\n";
echo " | ".stripslashes($ob->appName)." | \n";
echo " $desc | \n";
echo "
\n\n";
$c++;
}
echo "
\n\n";
echo html_frame_end();
}
/* display the versions */
function display_versions($appId, $versions)
{
if ($versions)
{
echo html_frame_start("","98%","",0);
echo "\n\n";
echo "\n";
echo " | Version | \n";
echo " Description | \n";
echo " Rating With Windows | \n";
echo " Rating Without Windows | \n";
echo " Comments | \n";
echo "
\n\n";
$c = 0;
while(list($idx, $ver) = each($versions))
{
//set row color
$bgcolor = (($c % 2) ? "color0" : "color1");
//format desc
$desc = substr(stripslashes($ver->description),0,75);
if(strlen($desc) == 75)
$desc .= " ...";
//get ratings
$r_win = rating_stars_for_version($ver->versionId, "windows");
$r_fake = rating_stars_for_version($ver->versionId, "fake");
//count comments
$r_count = count_comments($appId,$ver->versionId);
//display row
echo "\n";
echo " | ".$ver->versionName." | \n";
echo " $desc | \n";
echo " $r_win | \n";
echo " $r_fake | \n";
echo " $r_count | \n";
echo "
\n\n";
$c++;
}
echo "
\n";
echo html_frame_end("Click the Version Name to view the details of that Version");
}
}
/* code to View an application's Bugs */
$appId = $_REQUEST['appId'];
if(!is_numeric($appId))
{
errorpage("Something went wrong with the IDs");
exit;
}
if($appId)
{
$app = new Application($appId);
$data = $app->data;
if(!$data) {
// Oops! application not found or other error. do something
errorpage('Internal Database Access Error');
exit;
}
// header
apidb_header("Search for bugs in Bugzila for - ".$data->appName);
//cat display
display_catpath($app->data->catId, $appId);
//set Vendor
$vendor = $app->getVendor();
//set URL
$appLinkURL = ($data->webPage) ? "".substr(stripslashes($data->webPage),0,30)."": " ";
//set Image
$img = get_screenshot_img($appId, $versionId);
//start display application
echo html_frame_start("","98%","",0);
echo '| ',"\n";
echo ' | \n";
//Notes
echo "Welcome \n";
?>
This is the link between the Wine Application Database and Wine's Buzilla. From here you
get search for bugs entered against this application. You can also enter new bugs if you log
into Wine's Bugzilla.
The link between the Application Database and Bugzilla is based on the bug having the following URL
echo "
".APPDB_OWNER_URL."appview.php?appId=".$data->appId." \n";
?>
in the bug's "URL" Field. If it is not entered, this search page can not find it.
echo " | \n";
echo html_frame_end("For more details and user comments, view the versions of this application.");
//display versions
display_versions($appId,$app->getAppVersionList());
//display bundle
display_bundle($appId);
}
else
{
// Oops! Called with no params, bad llamah!
errorpage('Page Called with No Params!');
exit;
}
echo p();
apidb_footer();
?>
|