[SOLVED] More then one slider item breaks 1.8.0 Classic UI

Just to make sure I created a new sitemap with one slider:

sitemap foo label="Main Menu"
{
        Frame {
                Text label="Main Basement" icon="cellar" {
                        Slider item=Basement_Light_Master
                }       
        }
}

Works fine, no errors, but if I add two I get:

Uncaught TypeError: Cannot set property 'innerHTML' of undefined in Logic.min.js

sitemap foo label="Main Menu"
{
        Frame {
                Text label="Main Basement" icon="cellar" {
                        Slider item=Basement_Light_Master
                        Slider item=Basement_Light_Slave
                }       
        }
}

A nearly identical error was mentioned here:

Well, the slider function broke in 1.7.0 on the browser Classic UI (works fine on iOS app), but this issue actually breaks the page load! If you put more then one slider on a page the browser page locks with that error, the sliders themselves are never rendered.

If you use one slider, your back to the broken but very visible slider. :wink:

The issue is targeted at 1.8.1, so hopefully a developer will get to it soon.

Should I open a new issue? The issue you mentioned is about how the slider works, the issue I am reporting breaks the whole UI if you have more then one slider on a page. Ya, I want the slider to work, but with the issue I am reporting you can’t even use the rest of the UI if you have two sliders on a page!

It wouldn’t hurt to open a new issue, but I think the issues are very similar and related to not-working-as-intended UI code. Perhaps reference issue #2900 in your new issue, so they can address your results as well if they are different issues.

The thread Classic UI 1.8 RC appears to be the same problem. I also see this in chrome’s console:

GET https://192.168.1.2:8443/%22https://192.168.1.2:8443/classicui/WebApp/Design/Img/loader-gray-100x12x2.png%22 404 (ProxyServlet: /%22https://192.168.1.2:8443/classicui/WebApp/Design/Img/loader-gray-100x12x2.png%22)

Yep, but I think the real issue are the TypeErrors.

Same issue here, as soon as I add a slider, the GUI keeps empty

I also have the same issue. ;-(

Thanks for letting us know, guys! I’ll hope to get @sebastian or @vladvic on board. Do we have a consolidated Issue/Thread?

I have been trying to tie closely related reports and issues to #2900, which is already marked for 1.8.1.

For those who are affected by this: Try to add the value to the label in the sitemap or item. E.g. change MySlider to MySlider [%s %%] in a sitemap or add it to the item definition.
This case is covered in a Pull Request for 1.8.1.

5 Likes

Works! Not only can you display more then one, the slider actually works!

fyi, i am going to revert the slider changes to 1.8 for various reasons (see PR https://github.com/openhab/openhab/pull/4051)