Fix maintainer::objectGetEntries(). Remove UNION SELECT and properly check for application
queue status for un-queued maintainers
This commit is contained in:
committed by
WineHQ
parent
641e1c32f6
commit
4d5b566a78
@@ -197,29 +197,32 @@ class maintainer
|
|||||||
{
|
{
|
||||||
/* Excluding requests for queued apps and versions, as these will be
|
/* Excluding requests for queued apps and versions, as these will be
|
||||||
handled automatically */
|
handled automatically */
|
||||||
if($bQueued)
|
$sQuery = "SELECT DISTINCT maintainerId, appMaintainers.submitTime FROM
|
||||||
$sQuery = "SELECT appMaintainers.submitTime, maintainerId FROM
|
appMaintainers, appFamily, appVersion WHERE
|
||||||
appMaintainers, user_list, appFamily
|
appMaintainers.queued = '?'
|
||||||
WHERE appMaintainers.userid = user_list.userid AND
|
AND
|
||||||
appMaintainers.queued = '?' AND appMaintainers.appId =
|
appFamily.appId = appVersion.appId
|
||||||
appFamily.appId AND appMaintainers.versionId = '' AND
|
AND
|
||||||
appFamily.queued = 'false' UNION SELECT
|
(
|
||||||
appMaintainers.submitTime, maintainerId FROM
|
(
|
||||||
appMaintainers, user_list, appVersion WHERE
|
appFamily.appId = appMaintainers.appId
|
||||||
user_list.userid = appMaintainers.userid AND
|
AND
|
||||||
appMaintainers.versionId = appVersion.versionId AND
|
appFamily.queued = 'false'
|
||||||
appVersion.queued = 'false' AND appMaintainers.queued = '?'
|
AND
|
||||||
ORDER by submitTime";
|
appMaintainers.versionId = ''
|
||||||
else
|
)
|
||||||
$sQuery = "SELECT maintainerId FROM appMaintainers, user_list
|
OR
|
||||||
WHERE appMaintainers.userid = user_list.userid ".
|
(
|
||||||
"AND queued = '?' ORDER by realname";
|
appVersion.versionId = appMaintainers.versionId
|
||||||
|
AND
|
||||||
|
appVersion.queued = 'false'
|
||||||
|
)
|
||||||
|
)";
|
||||||
|
|
||||||
if($bQueued)
|
if($bQueued)
|
||||||
{
|
{
|
||||||
if($_SESSION['current']->hasPriv("admin"))
|
if($_SESSION['current']->hasPriv("admin"))
|
||||||
return query_parameters($sQuery, $bQueued ? "true" : "false",
|
return query_parameters($sQuery, $bQueued ? "true" : "false");
|
||||||
$bQueued ? "true" : "false");
|
|
||||||
else
|
else
|
||||||
return NULL;
|
return NULL;
|
||||||
} else
|
} else
|
||||||
|
|||||||
Reference in New Issue
Block a user