update config permission
This commit is contained in:
@@ -152,9 +152,15 @@ class ConfigController extends Controller {
|
||||
'method' => "POST"
|
||||
]
|
||||
];
|
||||
$apiConfig = json_decode(file_get_contents("http://localhost:4004/ReadAPIConfig", false, stream_context_create($options)), true);
|
||||
$ip = "192.168.0.42";
|
||||
$tempConfig = json_decode(file_get_contents("http://localhost:4004/ReadAPIConfig", false, stream_context_create($options)), true);
|
||||
if ($tempConfig['status']) {
|
||||
$t = json_decode($tempConfig['data'], true);
|
||||
$temp = explode(":", $t['servermqtt']);
|
||||
$ip = $temp[0];
|
||||
}
|
||||
return $this->render('index', [
|
||||
"apiConfig" => $apiConfig
|
||||
"ip" => $ip
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user