openhab / openhab-webui

Web UIs of openHAB
Eclipse Public License 2.0
218 stars 238 forks source link

Sitemap-element Webview #838

Closed FloriGlori closed 3 years ago

FloriGlori commented 3 years ago

I have already raised my problem in the openHAB Community and have been referred to you.

Problems with the uicomponents Sitmap Setup, Configuration and Use Items & Sitemaps openhab3

I want to write my new sitemap with the new Web-interface. In the setting of “Pages” I wanted to insert a Webview URL with Height = 10 for the Android App. Unfortunately, Openhab throws a severe error in the log afterwards: 2021-01-22 20:45:17.443 [ERROR] [omponents.UIComponentSitemapProvider] - Cannot build sitemap Home2

java.lang.ClassCastException: class java.math.BigDecimal cannot be cast to class java.lang.Integer (java.math.BigDecimal and java.lang.Integer are in module java.base of loader ‘bootstrap’)

at org.openhab.core.model.sitemap.sitemap.impl.WebviewImpl.eSet(WebviewImpl.java:171) ~[bundleFile:?]

at org.openhab.core.ui.internal.components.UIComponentSitemapProvider.setWidgetPropertyFromComponentConfig(UIComponentSitemapProvider.java:286) ~[bundleFile:?] […]

… The sitemap file from Openhab 2.5 has accepted the webview element. An addition. Without the “Height” variable it works. Unfortunately, it is then only one line high and cannot be displayed in example at the androidapp.

Expected behavior

Steps to reproduce

Your environment

Browser console

Browser network traffic

Additional information

bigbasec commented 3 years ago

Should already be fixed by : https://github.com/openhab/openhab-core/commit/fcaf251bd0f06995a449b4a2f412f068b6290e8c#diff-9a180bc00b6da393b95f066c8f2987f47221d89f8ee4209db49ca5c49883f42f

lolodomo commented 3 years ago

I believe #ghys fixed these casting bugs recently after the 3.0 release. Did you test with a relatively recent snapshot? If not, I suggest you close the issue and reopen it later if you still notice it after moving to a more recent version.

bigbasec commented 3 years ago

Yea, this is not an issue on snapshot right now.

lolodomo commented 3 years ago

So to be closed.