- Issue created by @penyaskito
- Status changed to Needs review
over 1 year ago 4:31am 17 March 2023 - πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
Attached screenshot
- πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
PR with tugboat preview at https://github.com/penyaskito/dashboard-initiative/pull/9
- Status changed to RTBC
over 1 year ago 6:18am 17 March 2023 - πͺπΈSpain plopesc Valladolid
Tested and looks great!
Just a few minor comments that can be addressed once we have all the pieces together.
- Find a way to refresh local actions cache once dashboards weights are modified from the UI. Changes are not reflected automatically
- I think that default dashboard should be excluded in
DashboardLocalTask::getDerivativeDefinitions
. Or remove the "Default Dashboard" Having 2 local tasks pointing to the same dashboard can be confusing
Thank you!
- πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
Find a way to refresh local actions cache once dashboards weights are modified from the UI. Changes are not reflected automatically
Unless we work on π Allow plugin derivers to specify cache tags for their definitions Postponed: needs info , we need to do this manually on dashboard save.
I think that default dashboard should be excluded in DashboardLocalTask::getDerivativeDefinitions. Or remove the "Default Dashboard" Having 2 local tasks pointing to the same dashboard can be confusing
That's the problem. For the former, we don't know what the default dashboard is, as it will vary per user permissions, and local tasks are site-wide. For the latter, then we don't have the "parent" route for the local tasks (or will not be available if the user has not permissions for that one).
- Status changed to Needs work
over 1 year ago 7:08am 17 March 2023 - πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
Thanks for reviewing :-)
I'm putting this back to NW, so we cover point 1 from your review, and add tests.
- πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
Is this enough for #4.1?
- πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
Pablo suggested hook_menu_local_tasks_alter and got it to work. Attached patch. We just need tests now :-)
- Assigned to gxleano
- πͺπΈSpain gxleano CΓ‘ceres
Answering comment #7 β¨ Show dashboards as local tasks Fixed , on my eyes it should be enough from now, I've tested modifying the weight of the different dashboard and it is automatically modified.
About comment #8 β¨ Show dashboards as local tasks Fixed , also tested, we are not showing two local tasks pointing to the same dashboard anymore.
@penyaskito, should we move this issue to RTBC?
- Status changed to Needs review
over 1 year ago 7:54am 27 April 2023 - πͺπΈSpain plopesc Valladolid
Attaching new iteration including automated tests for the Local Tasks.
We might need to discuss whether the "Administer dashboard" permission. bypass access to all the dashboards in /admin/dashboard, or the dashboard status and/or individual permissions should take precedence.
- Issue was unassigned.
- πͺπΈSpain plopesc Valladolid
Hi!
While working on the tests for this one, I realize that we need to determine the behavior for users that have "Administer Dashboards" permission.
In theory, this permissions bypass access to the dashboard entities. With the current behavior all the dashboards would be available, even the unpublished ones as local tasks in
/admin/dashboard
.This might make the
/admin/dashboard
page messy for these users. On the other hand, this is the only place where admin users can see the different dashboards.I thought about this and here is a different proposal to maintain
/admin/dashboard
page cleaner:- Dashboard page (
/admin/dashboard
) will include only the dashboards the users has access to based on the individual dashboard permissions - When managing the dashboard a new
Preview
tab will be added/admin/structure/dashboard/{dashboard}/preview
from where users with permissions to edit the dashboard will be able to see the same output as in /admin/dashboard/{dashboard}
, even if they don't have explicit access to the dashboard.
What do you think? Should we deal with this as part of this issue or move the discussion to a separate one?
- Dashboard page (
- πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
I love the idea!
I'd think we should take that as a follow-up though and try to get things closed.
- πͺπΈSpain plopesc Valladolid
Agreed!
Let's close this one and open the follow-up then.
- Status changed to Fixed
over 1 year ago 9:42am 9 May 2023 - πͺπΈSpain penyaskito Seville π, Spain πͺπΈ, UTC+2 πͺπΊ
Didn't test this locally but code review looks good. I'm committing this.
Automatically closed - issue fixed for 2 weeks with no activity.
- Status changed to Fixed
11 months ago 11:38am 10 January 2024