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

Dashboard app: Disabling the weather and status widgets is not consistent #22468

Closed
szaimen opened this issue Aug 27, 2020 · 12 comments
Closed
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug

Comments

@szaimen
Copy link
Contributor

szaimen commented Aug 27, 2020

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Steps to reproduce

  1. Update to NC 20 beta 2
  2. see the new dashboard app
  3. disable the weather and status widgets
  4. the weather and status widgets are now invisible
  5. force a reload of the side
  6. the weather and status widgets are now visible again

Expected behaviour

They should still be unvisible

Actual behaviour

they are visible

Server configuration

Nextcloud version: (see Nextcloud admin page)
NC 20 beta 2
Updated from an older Nextcloud/ownCloud or fresh install:
updated from NC 19.0.1
Where did you install Nextcloud from:
NcVM

@szaimen szaimen added bug 0. Needs triage Pending check for reproducibility or if it fits our roadmap labels Aug 27, 2020
@szaimen szaimen changed the title Dashboard app: Disabling The weather and status widgets is not consistent Dashboard app: Disabling the weather and status widgets is not consistent Aug 27, 2020
@szaimen
Copy link
Contributor Author

szaimen commented Aug 28, 2020

@nextcloud/designers I wonder if it is
meant to be this way?

@skjnldsv
Copy link
Member

cc @juliushaertl @eneiluj

@julien-nc
Copy link
Member

@szaimen It is not meant to be this way 😁. I can't reproduce this problem. Could you run this SQL query ?

select configvalue from oc_preferences where appid="dashboard" and configkey="statuses"

After having disabled the statuses, you are supposed to get {"weather":false,"status":false}.

Also, is there any error in the browser error log or the server logs when you toggle a status?

@szaimen
Copy link
Contributor Author

szaimen commented Aug 31, 2020

This is the output when running the command:
image

This is what the following command returns:
image

Those are the console logs:
image

In the nextcloud logs, I get nothing related.

@eneiluj Could it be a problem, that I am running a Postgresql database?

@julien-nc
Copy link
Member

julien-nc commented Aug 31, 2020

Could it be a problem, that I am running a Postgresql database?

@szaimen I don't think so as other values are successfully written to your oc_preferences table.

  1. Could you check if the request to "/apps/dashboard/statuses" is failing or not in the network tab of developer tools? The request JSON parameters is supposed to be
statuses: "{\"weather\":true,\"status\":false}"
  1. Is the widget layout saved correctly? If not, then the problem is larger...

@juliushaertl Any clue of what is happening there?

@szaimen
Copy link
Contributor Author

szaimen commented Aug 31, 2020

Thanks for your respond!

for 1.: This is what I get in the network tab when modifying the weather and status widgets:
image

for 2.: The layout is saved correctly until I reload the site. Then it just shows those widgets again, also if I had disabled them before. (probably because the statuses value(s) isn't saved correctly into the database)

@julien-nc
Copy link
Member

@szaimen Which browser are you using? Could you try with another one?

Widget activation, widget layout and statuses activation are all supposed to be saved and restored on page load. For the moment I have no idea what happens to you but it seems nothing is saved.

@szaimen
Copy link
Contributor Author

szaimen commented Aug 31, 2020

I've tested this on Brave, which is based on Chromium 85.
But the same happens on Firefox 80, too.
image

but it seems nothing is saved.

This is not true. The layout of the app-widgets like recent files and recent statuses is saved and restored correctly. (But this is most likely stored in a layout respond? and not in the status respond?)
Only the weather and status widgets have this problem.

@julien-nc
Copy link
Member

I thought you said the widgets layout was not saved.

Anyway I found the problem. I'll fix that soon. Thanks for your perseverance 👍

julien-nc pushed a commit that referenced this issue Aug 31, 2020
…t in UI

Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
@julien-nc
Copy link
Member

@szaimen Ok fixed. Could you try fix/save-statuses branch and confirm it now works fine?

@szaimen
Copy link
Contributor Author

szaimen commented Aug 31, 2020

I thought you said the widgets layout was not saved.

Sry, maybe I wasn't clear enough.

Anyway I found the problem. I'll fix that soon. Thanks for your perseverance 👍

Great!

@szaimen Ok fixed. Could you try fix/save-statuses branch and confirm it now works fine?

@eneiluj Yes, I've tried the fix by simply copying the content to the correct file and it fixes the issue. Thank you very much!

julien-nc pushed a commit that referenced this issue Sep 1, 2020
…t in UI

Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
julien-nc pushed a commit that referenced this issue Sep 1, 2020
…t in UI

Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
julien-nc pushed a commit that referenced this issue Sep 1, 2020
…t in UI

Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
julien-nc pushed a commit that referenced this issue Sep 4, 2020
…t in UI

Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
@szaimen
Copy link
Contributor Author

szaimen commented Sep 6, 2020

I guess this can be closed since the fix was merged

@szaimen szaimen closed this as completed Sep 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug
Projects
None yet
Development

No branches or pull requests

3 participants