mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-26 20:18:52 +02:00
N°2249 - Supportability - Updater module (split ajax calls)
This commit is contained in:
@@ -155,6 +155,24 @@ class AjaxController extends Controller
|
||||
$this->DisplayJSONPage($aParams, $iResponseCode);
|
||||
}
|
||||
|
||||
public function OperationCheckCompile()
|
||||
{
|
||||
$aParams = array();
|
||||
try
|
||||
{
|
||||
CoreUpdater::CheckCompile();
|
||||
$iResponseCode = 200;
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
IssueLog::Error("Compile: ".$e->getMessage());
|
||||
$aParams['sError'] = $e->getMessage();
|
||||
$iResponseCode = 500;
|
||||
}
|
||||
|
||||
$this->DisplayJSONPage($aParams, $iResponseCode);
|
||||
}
|
||||
|
||||
public function OperationCompile()
|
||||
{
|
||||
$aParams = array();
|
||||
@@ -163,7 +181,25 @@ class AjaxController extends Controller
|
||||
CoreUpdater::Compile();
|
||||
$iResponseCode = 200;
|
||||
}
|
||||
catch (Exception $e)
|
||||
catch (Exception $e)
|
||||
{
|
||||
IssueLog::Error("Compile: ".$e->getMessage());
|
||||
$aParams['sError'] = $e->getMessage();
|
||||
$iResponseCode = 500;
|
||||
}
|
||||
|
||||
$this->DisplayJSONPage($aParams, $iResponseCode);
|
||||
}
|
||||
|
||||
public function OperationUpdateDatabase()
|
||||
{
|
||||
$aParams = array();
|
||||
try
|
||||
{
|
||||
CoreUpdater::UpdateUpdateDatabase();
|
||||
$iResponseCode = 200;
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
IssueLog::Error("Compile: ".$e->getMessage());
|
||||
$aParams['sError'] = $e->getMessage();
|
||||
|
||||
Reference in New Issue
Block a user