Ich mache einen PR, sobald die Bestätigung von Tommi da ist, dass das Widget so funktioniert.
Ankündigung
Einklappen
Keine Ankündigung bisher.
Simulation plugin
Einklappen
X
-
Danke für den Hinweis, ich habe es im smartVISU Verzeichnis geändert und durch die Autogenerierung tatsächlich wieder überschrieben🙄. Nach einer erneuten Änderung ohne Neustart kann ich bestätigen das es funktioniert - schaut gut aus.
Außerdem sehe ich gerade das ich wohl schonmal im Admin Interface mit den Variablen rumgespielt hatte da schon ein paar Aktionen aufgenommen wurden... ;-)
Bei mir schaut die Datei jetzt folgendermaßen aus (ich werde die Datei im Plugin Verzeichnis überschreiben da ich weiter an der Visu mittels Autogenerierung bastle):
HTML-Code:* @license GPL [http://www.gnu.de] * ----------------------------------------------------------------------------- */ /** * Simulation Plugin widget. Shows all the relevant info for a simulation. * * @param {id=} unique id for this widget (optional) * @param {text=Anwesenheitssimulation} header. Optional, default=Anwesenheitssimulation * @param {item(num)} the simulation status item * @param {item(num)} the simulation tank item * @param {item(num)} the simulation control item * @param {item(str)} the simulation message item */ {% macro info(id, header, status, tank, control, message) %} {% import "basic.html" as basic %} {% if header is empty %} {% set text = "Anwesenheitssimulation" %} {% endif %} <div class="block" id="{{ uid(page, id) }}"> <div class="set-2" data-role="collapsible-set" data-theme="c" data-content-theme="a" data-mini="true"> <div data-role="collapsible" data-collapsed="false"> <h3>{{header}}</h3> <table width=100%> <tr> <td>{{ basic.symbol('',status,'','lamp_sim.svg',['4','0','1','2','3'],'',['#0b0','#A4A4A4','#A4A4A4','#A4A4A4','#A4A4A4']) }}</td> <td>Aufgenommene Tage<br>{{ basic.print('', tank) }}</td> <td>{{ basic.symbol('',status,'','lamp_sim.svg',['0','4','1','2','3'],'',['#A4A4A4','#A4A4A4','#fa3','#f00','#BF00FF']) }}</td> <td rowspan=3 width="20%">{{ basic.tank('P_tank1', tank,0,15,1,'cylinder','#0C0') }}</td> </tr><tr> <td>{{ basic.stateswitch('', control, 'mini', '2', 'audio_play.svg', '', '') }}</td> <td>{{ basic.stateswitch('', control, 'mini', '1', 'audio_stop.svg', '', '') }}</td> <td>{{ basic.stateswitch('', control, 'mini', '3', 'audio_rec.svg', '', '') }}</td> <td></td> </tr><tr> <td colspan=3 width="80%">{{basic.print('',message, 'html') }}</td> <td></td> </tr> </table> </div> </div> </div> {% endmacro %}
Viele Grüße
TommiAngehängte Dateien
Kommentar
Kommentar