Start to move maintainer related functions into maintainer class and separate maintainer related queries and logic from
display code. Also move maintainer related code from the user class. Fix up unit tests to work with the new maintainer class.
This commit is contained in:
@@ -85,12 +85,14 @@ if( $aClean['sMaintainReason'] )
|
||||
apidb_header("Submit Maintainer Request");
|
||||
|
||||
// add to queue
|
||||
$hResult = query_parameters("INSERT INTO appMaintainers (appId, versionId, ".
|
||||
"userId, maintainReason, superMaintainer, submitTime, queued) ".
|
||||
"VALUES ('?', '?', '?', '?', '?', ?, '?')",
|
||||
$aClean['iAppId'], $aClean['iVersionId'],
|
||||
$_SESSION['current']->iUserId, $aClean['sMaintainReason'],
|
||||
$aClean['iSuperMaintainer'], "NOW()", 'true');
|
||||
$oMaintainer = new Maintainer();
|
||||
$oMaintainer->iAppId = $aClean['iAppId'];
|
||||
$oMaintainer->iVersionId = $aClean['iVersionId'];
|
||||
$oMaintainer->iUserId = $_SESSION['current']->iUserId;
|
||||
$oMaintainer->sMaintainReason = $aClean['sMaintainReason'];
|
||||
$oMaintainer->bSuperMaintainer = $aClean['iSuperMaintainer'];
|
||||
|
||||
$hResult = $oMaintainer->create();
|
||||
|
||||
if ($hResult)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user