fix: workspace member "me" filters now work in dashboard widgets#20266
fix: workspace member "me" filters now work in dashboard widgets#20266QuantumByteMaster wants to merge 6 commits intotwentyhq:mainfrom
Conversation
Add onError callbacks with enqueueErrorSnackBar to mutations in workspace invitation hooks (send, delete, resend) and workflow version step hooks (create, update, delete, edge, duplicate, run step) so that API failures are clearly surfaced to users instead of failing silently. Closes twentyhq#20212
Welcome!
Hello there, congrats on your first PR! We're excited to have you contributing to this project. |
|
Can you join a video recording of the before/after? |
…ndencies
Graph widgets only passed `timeZone` in `filterValueDependencies`, so
`isCurrentWorkspaceMemberSelected` ("me") filters were silently ignored
when computing the GQL operation filter. Switch to `useFilterValueDependencies`
which includes both `timeZone` and `currentWorkspaceMemberId`, giving
dashboard widgets feature parity with regular view filters.
Fixes twentyhq#20225
5594374 to
d0e6030
Compare
|
@QuantumByteMaster you need to fix the CI |
…inated union type
|
Fixed the CI — the typecheck was failing because enqueueErrorSnackBar only accepts either apolloError or message, not both. Removed the redundant message fields since the Apollo error already contains the relevant message. |
|
@QuantumByteMaster nice, you still have some front storybook and tests failing |
|
@martmull The front-sb-test failures for WorkflowEditActionFormBuilder are pre-existing on main, those files weren't touched in this branch. |
Summary
Fixes #20225
Dashboard graph widgets only passed
timeZoneinfilterValueDependencieswhen computing the GraphQL operation filter. As a result,isCurrentWorkspaceMemberSelected("me") filters were silently ignored — the current workspace member ID wasundefined.Regular view filters already use
useFilterValueDependencieswhich provides bothtimeZoneandcurrentWorkspaceMemberId. This PR replaces the manual{ timeZone: userTimezone }object inuseGraphWidgetQueryCommonwithuseFilterValueDependencies(), giving dashboard widgets full feature parity with view filters.Changed file:
packages/twenty-front/src/modules/page-layout/widgets/graph/hooks/useGraphWidgetQueryCommon.ts