-
-
Notifications
You must be signed in to change notification settings - Fork 42
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
[change] Allow relative paths #249
Comments
Hi @nemesisdesign, I wanted to contribute to this issue if it is still open, I have installed the openwisp-notifications and the setup part is done for the same, I wanted the steps like how can I reproduce the issue based on which I can change the code |
Steps to replicate the issue
Actual result Expected result |
@pandafy I am Working on this issue. |
It is important to update the ALLOWED_HOSTS = ['internal.openwisp.test', 'external.openwisp.test', '127.0.0.1'] Thanks to @arup1221 for reporting this in the developer chat. 👏🏼 |
Thanks also, @pandafy, for allowing me to work on this project. I am currently figuring out whether this bug is related to notification generation and how to redirect it to |
The To understand the issue better, check the HTML code of the rendered notification element in the UI Here, an absolute URL is used for the device. We want to have the relative URL so that the URL works across different hostnames. What's the catch? The same logic is used for adding notification message in the emails. We want the emails to continue having absolute URLs, otherwise users would not be able to follow the URL to OpenWISP. |
JS code to implement this change + one selenium test. Closes: #249 --------- Co-authored-by: Federico Capoano <[email protected]>
JS code to implement this change + one selenium test. Closes: #249 --------- Co-authored-by: Federico Capoano <[email protected]>
It would be good to change the notification widget to allow the use of relative paths.
This helps the notification links to work also on systems which are using multiple domain names, some times a domain is reachable only from a private network but when users click on the notifications they are taken to the main domain name, which is not what they want.
The text was updated successfully, but these errors were encountered: