semikolon falsch gesetzt

This commit is contained in:
2024-12-17 16:10:29 +01:00
parent 7d5c3e358a
commit 91e383a36a
2 changed files with 7 additions and 6 deletions

View File

@@ -251,7 +251,7 @@ class Ladestation_Universal extends IPSModule
$baseUrl ="http://" . $this->ReadPropertyString("IP_Adresse") . "/api/set?";
}elseif(ReadPropertyInteger("Ladestation")==1){
$baseUrl ="http://" . $this->ReadPropertyString("IP_Adresse") . "/mqtt?payload=";
}
}
// Base URL
IPS_LogMessage("Ladestation", "Aufgerufene ip" . $baseUrl);
@@ -269,18 +269,17 @@ class Ladestation_Universal extends IPSModule
}elseif(ReadPropertyInteger("Ladestation")==1){
$url = $baseUrl . "alw=0";
}
}
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
return $response;
}
// For value between 1 and 32, make two requests
elseif ($value >= 1 && $value <= 32) {
// First request
if ($value == 0) {
if(ReadPropertyInteger("Ladestation")==2){
$url = $baseUrl . "frc=2";
}elseif(ReadPropertyInteger("Ladestation")==1){
@@ -299,7 +298,7 @@ class Ladestation_Universal extends IPSModule
// Second request
if ($value == 0) {
if(ReadPropertyInteger("Ladestation")==2){
$url2 = $baseUrl . "amp=$value";
}elseif(ReadPropertyInteger("Ladestation")==1){
@@ -326,6 +325,7 @@ class Ladestation_Universal extends IPSModule
else {
return "Invalid value. Must be between 0 and 32.";
}
}
public function convertPowerToCurrent($value, $Lademodus)
@@ -525,5 +525,6 @@ class Ladestation_Universal extends IPSModule
return $result;
}
}
?>

View File

@@ -6,7 +6,7 @@
"compatibility": {
"version": "7.1"
},
"version": "0.191",
"version": "0.192",
"build": 0,
"date": 0
}