I’m currently having two sitemaps in my system, one for myself, and one for a guest device. As I can only see one single sitemap in the app, I would like to embed the guest sitemap on some way into my own sitemap so I can check it myself, too.
However, there is already a number of posts mentioning that this does not appear to be possible at the moment. So I can neither say something like this …
Group sitemap="Guests" // imaginary syntax
… nor the following works, but it apparently did work in OH1:
Text label="<a href='/basicui/app?sitemap=Christoph'>Guest</a>" // does not parse the HTML, shows the raw source in the Basic UI
An absolute URL or an extra String item do not help, either.
Do you have any idea for me how I could succeed to embed/link to the sitemap Guests from the sitemap Home?
I really would find the Group sitemap= syntax proposed above helpful. Would you do so, too? I did not ever contribute to openHAB in past, is something like this on the way? If not, would this be a “good first issue” or is the actual design much more complex than a few hours of work?
I have no solution for embedding a different sitemap in a sitemap.
But as a workaround you can make a text frame in your sitemap and copy all the code from the other sitemap into that.
Example how i use sitemap:
sitemap Home label="Thuis"
//Label information met alle teksten
{
Frame label= Information{
//Presence, presence gaat aan wanneer mobiel connect
Text item= Presence label= "Precense" icon= presence labelcolor=[>ON="#1DB954",>OFF="#FFAFAF"]
{Frame label="Presence" {
Group item=Presence label= "People" icon= parents_2_3 labelcolor=[>ON="#1DB954",>OFF="#FFAFAF"]
}
}
Text item=Dateandtime labelcolor=["#808080"] valuecolor=["#808080"]
//Computer en devices settings
Text item= PCswitch label="Computer/Devices" icon= pc labelcolor=[>ON="#30A1FF",>OFF="red"]
{
Frame label="Computer" {
Switch item= PCswitch icon= pc labelcolor=[>ON="#30A1FF",>OFF="red"]
Switch item= PCFreddy labelcolor=[>ON="#30A1FF",>OFF="red"]
}
Frame label= "" visibility=[PCFreddy==ON]{
Webview url="http://192.168.2.108:8080/static/steam.html" icon=none
}
Frame label="Printer"
{Text item=printer labelcolor=["#808080"] valuecolor=["#808080"]
Text item=jamevents labelcolor=["#808080"] valuecolor=["#808080"]
Text item=totalpages labelcolor=["#808080"] valuecolor=["#808080"]
Group item=colorsprinter icon="printercolor" labelcolor=["#808080"] valuecolor=["#808080"]
}
Frame label="Raspberry Pi Info"{
Text item=systemmemoryused label="System Memory" labelcolor=["#b3446c"] valuecolor=["#b3446c"]
{Frame label="System memory" labelcolor=["#b3446c"] valuecolor=["#b3446c"]{
Text item=systemmemorytotal labelcolor=["#b3446c"] valuecolor=["#b3446c"]
Text item=systemmemoryavailable labelcolor=["#b3446c"] valuecolor=["#b3446c"]
Text item=systemmemoryused labelcolor=["#b3446c"] valuecolor=["#b3446c"]
}}
Text item=storageused label="System Storage" labelcolor=["#b3446c"] valuecolor=["#b3446c"]
{Frame label="System Storage"{
Text item=storagetotal labelcolor=["#b3446c"] valuecolor=["#b3446c"]
Text item=storageavailable labelcolor=["#b3446c"] valuecolor=["#b3446c"]
Text item=storageused labelcolor=["#b3446c"] valuecolor=["#b3446c"]
}}
Text item=cpuname labelcolor=["#b3446c"] valuecolor=["#b3446c"]
Text item=networkip labelcolor=["#b3446c"] valuecolor=["#b3446c"]
}
Frame label="Speedtest RPI"
{
Text item=SpeedtestResultDown labelcolor=["#03002F"] valuecolor=["#03002F"]
Text item=SpeedtestResultUp labelcolor=["#03002F"] valuecolor=["#03002F"]
Text item=SpeedtestResultPing labelcolor=["#03002F"] valuecolor=["#03002F"]
Text label="Speedtest Control" icon="speedtest_reload" labelcolor=["#03002F"] valuecolor=["#03002F"]
{Frame label= "speedtest"{
Text item=SpeedtestResultDate labelcolor=["#03002F"] valuecolor=["#03002F"]
Switch item=SpeedtestRerun mappings=[ON="Start"] labelcolor=["#03002F"] valuecolor=["#03002F"]
}}
}
Frame label="Master"{
Selection item=Flag_System label="System" mappings=[NULL="Active", Reboot="Reboot", PowerOff="Shut down"] labelcolor=["#b3446c"] valuecolor=["#b3446c"]
}
}
//Temperatuur en sensors
Group item= Temp label="Sensors [%.1f °C]" icon= "humidifier" labelcolor=["#30A1FF"] valuecolor=["#30A1FF"]
{Frame label="Sensors" {
Group item= Temp labelcolor=["#b3446c"] valuecolor=["#b3446c"]
Group item= Humidity labelcolor=["#30A1FF"] valuecolor=["#30A1FF"]
Group item= Licht labelcolor=["gold"] valuecolor=["gold"]
}
Frame label="Charts"{
Switch item=Chartdummy label="Charts Sensors" icon= "humidifier" mappings=[0="OFF", 1="Hour",2="Day",3="Week"]
Webview url="http://192.168.2.108:8080/static/grafanauur1.html" icon=none height=12 visibility=[Chartdummy==1]
Webview url="http://192.168.2.108:8080/static/grafanadag.html" icon=none height=12 visibility=[Chartdummy==2]
Webview url="http://192.168.2.108:8080/static/grafanaweek.html" icon=none height=12 visibility=[Chartdummy==3]
}
This is just a little part of the sitemap code
And that will look like this: