private static function testAppListRetrieval() { ReportInfo("Testing retrieval of a list of apps for an account..."); $account_id = 1; $apps = da_apps_registry::GetListOfApps($account_id); print_r($apps); if (count($apps) > 0) { ReportSuccess("Result seems to be fine."); } else { ReportSuccess("Result seems to be WRONG"); } }
/** * * * @return \simpleResponse */ function execute() { $response = new simpleResponse(); try { $account_id = 0; include './inc/incWebServiceSessionValidation.php'; if ($account_id > 0) { $apps = da_apps_registry::GetListOfApps($account_id); $response->status = "OK"; $response->message = "SUCCESS"; $response->data = $apps; } else { $response->status = "ERROR"; } } catch (Exception $ex) { $response->status = "EXCEPTION"; $response->message = $ex->getMessage(); } return $response; }