no message
This commit is contained in:
@@ -40,15 +40,15 @@ class PV_Visu extends IPSModule
|
||||
*/
|
||||
public function GetVisualizationTile()
|
||||
{
|
||||
$this->UpdateData();
|
||||
$initialHandling = '<script>handleMessage(' . json_encode($this->UpdateData()) . ');</script>';
|
||||
|
||||
// Füge statisches HTML aus Datei hinzu
|
||||
$module = file_get_contents(__DIR__ . '/module.html');
|
||||
|
||||
// Gebe alles zurück.
|
||||
// Wichtig: $initialHandling nach hinten, da die Funktion handleMessage ja erst im HTML definiert wird
|
||||
return $module . $initialHandling;
|
||||
|
||||
// HTML-Template laden und zurückgeben
|
||||
$htmlPath = __DIR__ . '/module.html';
|
||||
if (!file_exists($htmlPath)) {
|
||||
$this->LogMessage("module.html nicht gefunden in $htmlPath", KL_ERROR);
|
||||
return '';
|
||||
}
|
||||
return file_get_contents($htmlPath);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user