44 lines
1.5 KiB
PHP
44 lines
1.5 KiB
PHP
<?php
|
|
|
|
namespace App\Controllers;
|
|
|
|
class WrenchGeneralData extends BaseController
|
|
{
|
|
private $current_env=0;
|
|
private $primary_image_sever='';
|
|
private$server_tag='';
|
|
|
|
public function __construct()
|
|
{
|
|
$this->current_env = $this->getSiteConfigurations("system.live");
|
|
$this->primary_image_sever = $this->getSiteConfigurations("system.primary_image_sever");
|
|
$this->server_tag = $this->getSiteConfigurations("system.server_tag");
|
|
}
|
|
|
|
public function signUpCountry(){
|
|
$in["action"] = WRENCHBOARD_SIGNUP_COUNTRY;
|
|
|
|
|
|
$wrenchboard = new \App\Models\BackendModel();
|
|
$ret = $wrenchboard->wrenchboard_api($in, $out);
|
|
$out['internal_return'] = $ret;
|
|
|
|
$endpoint = "SIGNUP_COUNTRY-";
|
|
$this->saveCache($endpoint,$out,$timeLine=15000);
|
|
|
|
|
|
// $this->doCacheStep($in, $out);
|
|
$final_out = ( new \App\Models\ResultFormatter() )->processOutJson($in, $out);
|
|
$final_out["environment"] = $this->current_env + 0;
|
|
$final_out["session_image_server"] = $this->primary_image_sever;
|
|
$final_out["server_tag"] = $this->server_tag;
|
|
$final_out["language"] = "en";
|
|
$final_out["ip_loc"] = $this->getIpData();
|
|
$final_out["current_version"] = 20240306;
|
|
$final_out["family_types"] = $this->familyTypes();
|
|
$final_out["history_types"] = $this->historyTypes();
|
|
//return json_encode( ( new \App\Models\ResultFormatter() )->processOutJson($in, $out));
|
|
return json_encode( $final_out );
|
|
|
|
}
|
|
} |