NEWS
[GELÖST] Text-Wert eines states ausgeben anstatt Nummer
-
Oder alternativ ein anderes Widget wenn es nicht genau das sein muss?
Noch dein ObjectID auswählen und dann sollte das gehen
! ````
[{"tpl":"tplValueList","data":{"oid":"","g_fixed":false,"g_visibility":false,"g_css_font_text":false,"g_css_background":false,"g_css_shadow_padding":false,"g_css_border":false,"g_gestures":false,"g_signals":false,"g_last_change":false,"visibility-cond":"==","visibility-val":1,"visibility-groups-action":"hide","signals-cond-0":"==","signals-val-0":true,"signals-icon-0":"/vis/signals/lowbattery.png","signals-icon-size-0":0,"signals-blink-0":false,"signals-horz-0":0,"signals-vert-0":0,"signals-hide-edit-0":false,"signals-cond-1":"==","signals-val-1":true,"signals-icon-1":"/vis/signals/lowbattery.png","signals-icon-size-1":0,"signals-blink-1":false,"signals-horz-1":0,"signals-vert-1":0,"signals-hide-edit-1":false,"signals-cond-2":"==","signals-val-2":true,"signals-icon-2":"/vis/signals/lowbattery.png","signals-icon-size-2":0,"signals-blink-2":false,"signals-horz-2":0,"signals-vert-2":0,"signals-hide-edit-2":false,"lc-type":"last-change","lc-is-interval":true,"lc-is-moment":false,"lc-format":"","lc-position-vert":"top","lc-position-horz":"right","lc-offset-vert":0,"lc-offset-horz":0,"lc-font-size":"12px","lc-font-family":"","lc-font-style":"","lc-bkg-color":"","lc-color":"","lc-border-width":"0","lc-border-style":"","lc-border-color":"","lc-border-radius":10,"lc-zindex":0,"valuelist":"Unknown 1;\nSleep no Charge;\nSleep;\nCleaning;\nReturning;\nManuell mode;\nCharging;\nPaused;\nSpot cleaning;\nError?!"},"style":{"left":"174px","top":"137px","width":"100px","height":"30px"},"widgetSet":"basic"}] -
Danke für die Ideen. Ein neues Script und Datenpunkt wollte ich auf Grund der Übersichtlichkeit vermeiden. Habe mich daher für die Idee von peoples entschieden (musste nur die Werte-Liste noch anpassen da das Widget 0-basiert ist und die Status-Werte des Roboters "Lücken" hat). Aber so klappt es.
[{"tpl":"tplValueList","data":{"oid":"mihome-vacuum.0.info.state","g_fixed":false,"g_visibility":false,"g_css_font_text":true,"g_css_background":false,"g_css_shadow_padding":false,"g_css_border":false,"g_gestures":false,"g_signals":false,"g_last_change":false,"visibility-cond":"==","visibility-val":1,"visibility-groups-action":"hide","signals-cond-0":"==","signals-val-0":true,"signals-icon-0":"/vis/signals/lowbattery.png","signals-icon-size-0":0,"signals-blink-0":false,"signals-horz-0":0,"signals-vert-0":0,"signals-hide-edit-0":false,"signals-cond-1":"==","signals-val-1":true,"signals-icon-1":"/vis/signals/lowbattery.png","signals-icon-size-1":0,"signals-blink-1":false,"signals-horz-1":0,"signals-vert-1":0,"signals-hide-edit-1":false,"signals-cond-2":"==","signals-val-2":true,"signals-icon-2":"/vis/signals/lowbattery.png","signals-icon-size-2":0,"signals-blink-2":false,"signals-horz-2":0,"signals-vert-2":0,"signals-hide-edit-2":false,"lc-type":"last-change","lc-is-interval":true,"lc-is-moment":false,"lc-format":"","lc-position-vert":"top","lc-position-horz":"right","lc-offset-vert":0,"lc-offset-horz":0,"lc-font-size":"12px","lc-font-family":"","lc-font-style":"","lc-bkg-color":"","lc-color":"","lc-border-width":"0","lc-border-style":"","lc-border-color":"","lc-border-radius":10,"lc-zindex":0,"valuelist":"Unknown;\nUnknown;\nSleep no Charge;\nSleep;\nUnknown;\nCleaning;\nReturning home;\nManuell mode;\nCharging;\nUnknown;\nPaused;\nSpot cleaning;\nError"},"style":{"left":"433px","top":"18px","width":"110px","height":"20px","color":"#FFFFFF"},"widgetSet":"basic"}]
Danke euch!
-
@miggedy said in [GELÖST] Text-Wert eines states ausgeben anstatt Nummer:
[{"tpl":"tplValueList","data":{"oid":"mihome-vacuum.0.info.state","g_fixed":false,"g_visibility":false,"g_css_font_text":true,"g_css_background":false,"g_css_shadow_padding":false,"g_css_border":false,"g_gestures":false,"g_signals":false,"g_last_change":false,"visibility-cond":"==","visibility-val":1,"visibility-groups-action":"hide","signals-cond-0":"==","signals-val-0":true,"signals-icon-0":"/vis/signals/lowbattery.png","signals-icon-size-0":0,"signals-blink-0":false,"signals-horz-0":0,"signals-vert-0":0,"signals-hide-edit-0":false,"signals-cond-1":"==","signals-val-1":true,"signals-icon-1":"/vis/signals/lowbattery.png","signals-icon-size-1":0,"signals-blink-1":false,"signals-horz-1":0,"signals-vert-1":0,"signals-hide-edit-1":false,"signals-cond-2":"==","signals-val-2":true,"signals-icon-2":"/vis/signals/lowbattery.png","signals-icon-size-2":0,"signals-blink-2":false,"signals-horz-2":0,"signals-vert-2":0,"signals-hide-edit-2":false,"lc-type":"last-change","lc-is-interval":true,"lc-is-moment":false,"lc-format":"","lc-position-vert":"top","lc-position-horz":"right","lc-offset-vert":0,"lc-offset-horz":0,"lc-font-size":"12px","lc-font-family":"","lc-font-style":"","lc-bkg-color":"","lc-color":"","lc-border-width":"0","lc-border-style":"","lc-border-color":"","lc-border-radius":10,"lc-zindex":0,"valuelist":"Unknown;\nUnknown;\nSleep no Charge;\nSleep;\nUnknown;\nCleaning;\nReturning home;\nManuell mode;\nCharging;\nUnknown;\nPaused;\nSpot cleaning;\nError"},"style":{"left":"433px","top":"18px","width":"110px","height":"20px","color":"#FFFFFF"},"widgetSet":"basic"}]
Habe gerade genau das gleiche Problem
Welches Widget verwendet man für sowas? -
@tropisch said in [GELÖST] Text-Wert eines states ausgeben anstatt Nummer:
@miggedy said in [GELÖST] Text-Wert eines states ausgeben anstatt Nummer:
[{"tpl":"tplValueList","data":{"oid":"mihome-vacuum.0.info.state","g_fixed":false,"g_visibility":false,"g_css_font_text":true,"g_css_background":false,"g_css_shadow_padding":false,"g_css_border":false,"g_gestures":false,"g_signals":false,"g_last_change":false,"visibility-cond":"==","visibility-val":1,"visibility-groups-action":"hide","signals-cond-0":"==","signals-val-0":true,"signals-icon-0":"/vis/signals/lowbattery.png","signals-icon-size-0":0,"signals-blink-0":false,"signals-horz-0":0,"signals-vert-0":0,"signals-hide-edit-0":false,"signals-cond-1":"==","signals-val-1":true,"signals-icon-1":"/vis/signals/lowbattery.png","signals-icon-size-1":0,"signals-blink-1":false,"signals-horz-1":0,"signals-vert-1":0,"signals-hide-edit-1":false,"signals-cond-2":"==","signals-val-2":true,"signals-icon-2":"/vis/signals/lowbattery.png","signals-icon-size-2":0,"signals-blink-2":false,"signals-horz-2":0,"signals-vert-2":0,"signals-hide-edit-2":false,"lc-type":"last-change","lc-is-interval":true,"lc-is-moment":false,"lc-format":"","lc-position-vert":"top","lc-position-horz":"right","lc-offset-vert":0,"lc-offset-horz":0,"lc-font-size":"12px","lc-font-family":"","lc-font-style":"","lc-bkg-color":"","lc-color":"","lc-border-width":"0","lc-border-style":"","lc-border-color":"","lc-border-radius":10,"lc-zindex":0,"valuelist":"Unknown;\nUnknown;\nSleep no Charge;\nSleep;\nUnknown;\nCleaning;\nReturning home;\nManuell mode;\nCharging;\nUnknown;\nPaused;\nSpot cleaning;\nError"},"style":{"left":"433px","top":"18px","width":"110px","height":"20px","color":"#FFFFFF"},"widgetSet":"basic"}]
Habe gerade genau das gleiche Problem
Welches Widget verwendet man für sowas?Problem gelöst.
Falls noch jemand diese Frage hat: Widgets - Widgets importieren -
Ich habe bei meinem Landroid das gleiche Problem. Irgendwie muss es doch noch eine andere Lösung geben, Immerhin steht ja alles in der DP Definition drin und in der Admin Oberfläche wird auch der Klartext angezeigt.
-
-
Ja, nee... dass es damit geht (aber nur in der VIS), ist mir schon klar. Aber das heisst, dass ich bereits im System vorhandene Werte nochmal eingeben muss. Das sind für mich nur work-arounds. Denken wir mal, dass Worx einen zusätzlichen Status 99 - Dein Landroid hebt in zwei Minuten ab erfindet. Dann muss ich in vile Visualisierungen und Scripte anpassen.
Ich glaube ich mache mal ein GIT Issue auf - passt wahrscheinlich in ioBroker.javascript. -
@apollon77
Ich habe gesehen, dass Du einen Enhancement Request zu einem ähnlichen Thema aufgemacht hast (https://github.com/ioBroker/ioBroker.javascript/issues/381)
Kannst Du in diesem Thread helfen: Wie kann ich mit getState (oder getObject ?) an den Klartext eines State values kommen? -
Wenn ein Objekt sowas hat dann per getObject das Objekt laden und da unter common.states stehen die Textzeilen werte.
-
@apollon77 Super, danke, funktioniert
-
@apollon77 Danke, diese relativ alte Antwort hat auch mir heut geholfen!
-
@michaelsc said in [GELÖST] Text-Wert eines states ausgeben anstatt Nummer:
@apollon77 Danke, diese relativ alte Antwort hat auch mir heut geholfen!
@apollon77: Hat zwar geholfen, aber nicht zum Erfolg geführt - ich komme mit der Syntax nicht klar.
Wie muss denn bitte so ein getObject genau aussehen? Ich hätte gerne den Namen zurück, der da drinsteht, aber da muss man doch eine bestimmte Syntax einhalten, denke ich mal...