openhab / openhab-ios

The repository of the iOS client
Eclipse Public License 2.0
190 stars 127 forks source link

Icons don't update on openHAB 2 #65

Closed kaikreuzer closed 8 years ago

kaikreuzer commented 8 years ago

The app still expects a string like "rollershutter-40" as an icon parameter in the sitemap. In openHAB 2, this has been split into icon and state now - so you only receive "rollershutter" as the icon and you will have "40" as the state. From this, the HTTP request has to be assembled like in the past as 'icon/rollershutter-40.png' or alternatively (recommended!) as 'icon/rollershutter?state=40&format=png'.

See https://www.eclipse.org/smarthome/documentation/features/ui/icons.html#icon-servlet for details.

dennisausbremen commented 8 years ago

_Question: _ Does this issue include the fact that the iOS App does not load custom SVG/PNG Icons from "conf/icons/classic"?

kaikreuzer commented 8 years ago

Yes, I think it does. As nothing has happened on this critical issue since almost two months, I am wondering, if we have any iOS developers in the community that would jump in and create a PR with a fix...? It is a pity seeing the iOS app being abandoned :cry:

akw2si commented 7 years ago

There is still small mistake. I believe the app is using "state" value for {itemname} from /rest/items, but should take /items/{itemname}/state. Result of /rest/items have the state translated to custom name if transpormations are used as described at https://github.com/openhab/openhab1-addons/wiki/Explanation-of-items#transforming. Please introduce the change in the code.