cleanup scripts, will look for maintainers that have queued entries that the maintainer can process. If the queued entries aren't processed for X days an email is sent. In X*2 days another email is sent. After X*3 days the maintainer is stripped of their maintainership as they aren't really maintaining the application anyway. The hope is that this system lets maintainers know that they have pending queued entries to process to reduce the pressure on the appdb admins to handled hundreds of queued entries.
34 lines
801 B
PHP
34 lines
801 B
PHP
<?php
|
|
|
|
/* common functions used in appdb unit tests */
|
|
|
|
function test_start($sFunctionName)
|
|
{
|
|
echo $sFunctionName."() starting\n";
|
|
}
|
|
|
|
// create an application and a version of that application
|
|
// return the iVersionId of the created version
|
|
function create_version_and_parent_app()
|
|
{
|
|
$oApp = new application();
|
|
$oApp->sName = "OM App";
|
|
$oApp->create();
|
|
$oVersion = new version();
|
|
$oVersion->sName = "OM version";
|
|
$oVersion->iAppId = $oApp->iAppId;
|
|
$oVersion->create();
|
|
return $oVersion->iVersionId;
|
|
}
|
|
|
|
// delete a version based on the $iVersionId parameter
|
|
// and delete its parent application
|
|
function delete_version_and_parent_app($iVersionId)
|
|
{
|
|
$oVersion = new version($iVersionId);
|
|
$oApp = new application($oVersion->iAppId);
|
|
$oApp->delete();
|
|
}
|
|
|
|
?>
|