feat: add Views backend + frontend API layer (MUL-2704)#3351
Closed
NevilleQingNY wants to merge 5 commits into
Closed
feat: add Views backend + frontend API layer (MUL-2704)#3351NevilleQingNY wants to merge 5 commits into
NevilleQingNY wants to merge 5 commits into
Conversation
Implement saved_view table, CRUD handlers, lazy default creation,
12 new filter params on /api/issues ({me} token, involves 6-branch OR,
statuses, priorities, assignee_type, label_ids, etc.), plus frontend
types, schemas, API client methods, and TanStack Query hooks with
optimistic updates.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-authored-by: multica-agent <github@multica.ai>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…d integration (MUL-2704) Backend fixes: - A1: Validate project_id belongs to current workspace in ListViews/CreateView - A2: Export @multica/core/views subpath from package.json - A3: Fix filter key casing — assigneeType → assignee_type in default views - A4: Add canManageView auth check to ReorderViews handler - A5: Move hot-table indexes to migration 111 with CREATE INDEX CONCURRENTLY Frontend integration (steps 3-8): - Replace hardcoded scope tabs with dynamic view tabs loaded from server - Issues page and My Issues page fetch views via GET /api/views - Active view's filters are passed as server-side params to GET /api/issues - issueListOptions now accepts an optional filter param - viewFiltersToApiParams utility maps view JSON filters to API params - WS view events invalidate the views query cache - Thread viewFilter through BoardView/ListView/useLoadMoreByStatus for cache key consistency - Update tests to mock views API and verify new behavior Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Co-authored-by: multica-agent <github@multica.ai>
…ype cleanup
1. Fix non-default views resurrecting after deletion: ListViews now
seeds all presets only on first access (zero rows); subsequent calls
only ensure is_default=true views, so deleted presets stay deleted.
2. Add display JSONB column (migration 112) for view display settings
(viewMode, grouping, sort, cardProperties) — wired through backend
CRUD, Zod schema, and frontend types.
3. Remove unused position field from UpdateViewRequest.
4. Add comment explaining why My Issues resolves {me} client-side.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-authored-by: multica-agent <github@multica.ai>
Replace hardcoded scope tabs with dynamic view tabs loaded from the Views API. Supports creating custom views, renaming, deleting, and saving filter state. Default views (All/Members/Agents) map to scopes via known filter patterns; custom views serialize full filter state into the filters JSONB under a __custom key. New files: - packages/core/issues/stores/active-view-store.ts (persisted active view tracking) - packages/core/views/helpers.ts (serialize/deserialize/dirty detection) - packages/views/issues/components/view-tabs.tsx (reusable tab component) Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Co-authored-by: multica-agent <github@multica.ai>
Brings in the complete ViewTabs component, active-view-store, helpers (serialize/deserialize/dirty-check), and i18n locales that were developed on a separate worktree branch but never merged into the PR branch. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Co-authored-by: multica-agent <github@multica.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
saved_viewtable (migration 110) with CRUD handlers, lazy default view creation (Issues/My Issues/Project), 12 new filter params on/api/issues({me}token,involves6-branch OR,statuses,priorities,assignee_type,assignee_filters,creator_filters,project_ids,label_ids,include_no_assignee,include_no_project), WebSocket events, and performance indexes onagent(owner_id)andissue(creator_id)listIssuesfilter forwarding), TanStack Query hooks with optimistic updates (useCreateView,useUpdateView,useDeleteView,useReorderViews)/api/issues/groupedpreserved for desktop client compatibilityTest plan
go build ./...passesgo vet ./...passespnpm typecheckpasses (6/6 tasks)GET /api/views?page=issuesreturns lazy-created default viewsPOST /api/viewscreates a new viewPUT /api/views/:idupdates name/filters/sharedDELETE /api/views/:idblocks deletion of is_default=true viewsGET /api/issues?assignee={me}resolves to current userGET /api/issues?involves={me}returns all user-related issues (6-branch OR)GET /api/issues?statuses=todo,in_progressworks independently ofstatusparamassignee_id,creator_id,involves_user_id) still work🤖 Generated with Claude Code