version: Add 'pending' queue state
This commit is contained in:
committed by
Chris Morgan
parent
da471d1ad8
commit
62e3a98fca
@@ -92,7 +92,11 @@ class version {
|
|||||||
if(!$_SESSION['current']->canCreateVersion())
|
if(!$_SESSION['current']->canCreateVersion())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
$this->sQueued = $this->mustBeQueued() ? "true" : "false";
|
$oApp = new application($this->iAppId);
|
||||||
|
if($oApp->sQueued != "false")
|
||||||
|
$this->sQueued = "pending";
|
||||||
|
else
|
||||||
|
$this->sQueued = $this->mustBeQueued() ? "true" : "false";
|
||||||
|
|
||||||
$hResult = query_parameters("INSERT INTO appVersion
|
$hResult = query_parameters("INSERT INTO appVersion
|
||||||
(versionName, description, maintainer_release,
|
(versionName, description, maintainer_release,
|
||||||
@@ -274,7 +278,7 @@ class version {
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
// If we are not in the queue, we can't move the version out of the queue.
|
// If we are not in the queue, we can't move the version out of the queue.
|
||||||
if(!$this->sQueued == 'true')
|
if($this->sQueued == 'false')
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if(query_parameters("UPDATE appVersion SET queued = '?' WHERE versionId = '?'",
|
if(query_parameters("UPDATE appVersion SET queued = '?' WHERE versionId = '?'",
|
||||||
|
|||||||
@@ -52,7 +52,6 @@ class version_queue
|
|||||||
|
|
||||||
function reQueue()
|
function reQueue()
|
||||||
{
|
{
|
||||||
$this->oVersion->reQueue();
|
|
||||||
$this->oDownloadUrl->reQueue();
|
$this->oDownloadUrl->reQueue();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ create table appVersion (
|
|||||||
maintainer_release text,
|
maintainer_release text,
|
||||||
submitTime datetime NOT NULL,
|
submitTime datetime NOT NULL,
|
||||||
submitterId int(11) NOT NULL default '0',
|
submitterId int(11) NOT NULL default '0',
|
||||||
queued enum('true','false','rejected') NOT NULL default 'false',
|
queued enum('true','false','rejected','pending') NOT NULL default 'false',
|
||||||
license enum('Retail','Open Source','Freeware','Demo','Shareware'),
|
license enum('Retail','Open Source','Freeware','Demo','Shareware'),
|
||||||
obsoleteBy int(11) NOT NULL default '0',
|
obsoleteBy int(11) NOT NULL default '0',
|
||||||
key(versionId),
|
key(versionId),
|
||||||
|
|||||||
Reference in New Issue
Block a user