hasPriv("admin")) { errorpage("Insufficient privileges."); exit; } if($_REQUEST['sub'] == 'delete') { $oDistribution = new distribution($_REQUEST['iDistributionId']); $oDistribution->delete(); redirect($_SERVER['PHP_SELF']); } } $oDistribution = new distribution($_REQUEST['iDistributionId']); //exit with error if no vendor if(!$oDistribution->iDistributionId) { apidb_header("View Distributions"); //get available Distributions $sQuery = "SELECT distributionId FROM distributions ORDER BY name, distributionId;"; $hResult = query_appdb($sQuery); // show Distribution list echo html_frame_start("","90%","",0); echo "
| Distribution name | \n"; echo "Distribution url | \n"; echo "Linked Tests | \n"; if ($_SESSION['current']->hasPriv("admin")) echo "Action | \n"; echo "
| iDistributionId."\">","\n"; echo $oDistribution->sName." | \n"; echo "sUrl."\">".$oDistribution->sUrl." | \n"; echo "".sizeof($oDistribution->aTestingIds)." | \n"; if ($_SESSION['current']->hasPriv("admin")) { echo ""; echo "[edit]"; if(!sizeof($oDistribution->aTestingIds)) echo " [iDistributionId."'>delete]"; echo " | \n"; } echo "
Testing Results for '.$oDistribution->sName.'
',"\n";
echo '
| Application Version | ',"\n"; echo 'Submitter | ',"\n"; echo 'Date Submitted | ',"\n"; echo 'Wine version | ',"\n"; echo 'Installs? | ',"\n"; echo 'Runs? | ',"\n"; echo 'Rating | ',"\n"; echo '|
| ',"\n"; echo $oApp->sName.' '.$oVersion->sName.' | ',"\n"; echo '',"\n"; echo $oSubmitter->sEmail ? "sEmail."\">":""; echo $oSubmitter->sRealname; echo $oSubmitter->sEmail ? "":""; echo ' | ',"\n"; echo ''.date("M d Y", mysqltimestamp_to_unixtimestamp($oTest->sSubmitTime)).' | ',"\n"; echo ''.$oTest->sTestedRelease.'  | ',"\n"; echo ''.$oTest->sInstalls.'  | ',"\n"; echo ''.$oTest->sRuns.'  | ',"\n"; echo ''.$oTest->sTestedRating.'  | ',"\n"; if ($_SESSION['current']->hasAppVersionModifyPermission($oTest->iVersionId)) { echo '',"\n"; echo 'Edit | ',"\n"; } echo '