Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mainui] Non-existing url generated in browser address bar #2394

Open
seime opened this issue Feb 23, 2024 · 1 comment
Open

[mainui] Non-existing url generated in browser address bar #2394

seime opened this issue Feb 23, 2024 · 1 comment
Labels
bug Something isn't working main ui Main UI

Comments

@seime
Copy link
Contributor

seime commented Feb 23, 2024

The problem

When navigating in MainUI, a non-existant URL is generated by the UI. When doing browser reload, the URL is not found and an error page is shown:

CleanShot 2024-02-23 at 08 07 24@2x

Expected behavior

The browser address field is populated only with URLs that exists.

Steps to reproduce

  1. Open Settings -> Thingsand choose any Thing with at least one channel that is linked to an existing Item
  2. Click on Channels tab, choose any channel and click on the linked item:
    CleanShot 2024-02-23 at 08 10 39@2x
    You are taken to a page like
CleanShot 2024-02-23 at 08 12 58@2x
  1. In the browser, reload the page -> Page not found

Your environment

runtimeInfo:
  version: 4.1.1
  buildString: Release Build
locale: en-NO
  userAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36
    (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36
timestamp: 2024-02-23T07:15:46.836Z

Browser console

No messages

@seime seime added bug Something isn't working main ui Main UI labels Feb 23, 2024
@florian-h05
Copy link
Contributor

This is because the route to the link info page is not part of routes.js, so it works when navigating around, but when reloading the page, the router doesn’t find this page.

Fixing this would require a new route to be added to the router, however it the problem that the https://github.com/openhab/openhab-webui/blob/9f006fdff308610379d2982d5a7584c60eb51230/bundles/org.openhab.ui/web/src/pages/settings/things/link/link-edit.vue link-edit page would need to load the data it normally gets passed from https://github.com/openhab/openhab-webui/blob/9f006fdff308610379d2982d5a7584c60eb51230/bundles/org.openhab.ui/web/src/components/thing/channel-link.vue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working main ui Main UI
Projects
None yet
Development

No branches or pull requests

2 participants