feat: added board ordering in project using dnd#409
Open
kotserge wants to merge 1 commit intokanbn:mainfrom
Open
feat: added board ordering in project using dnd#409kotserge wants to merge 1 commit intokanbn:mainfrom
kotserge wants to merge 1 commit intokanbn:mainfrom
Conversation
hjball
reviewed
Feb 26, 2026
| @@ -0,0 +1,90 @@ | |||
| DO $$ BEGIN | |||
Contributor
There was a problem hiding this comment.
Not sure why these schema changes are being picked up. Did you run pnpm drizzle-kit generate? @kotserge
hjball
reviewed
Feb 26, 2026
| visibility: boardVisibilityEnum("visibility").notNull().default("private"), | ||
| type: boardTypeEnum("type").notNull().default("regular"), | ||
| sourceBoardId: bigint("sourceBoardId", { mode: "number" }), | ||
| position: integer("position").notNull(), |
Contributor
There was a problem hiding this comment.
This will update the position for all workspace members. Ideally we want to allow each user to customise the order of their boards so we'll need to do something similar to user_board_favourites.
In fact we should probably merge user_board_favourites into user_board and store position and isFavourite on there. That'll give us greater flexibility in future.
We'll need to:
- Create
board_usertable withuserId,boardId,position,isFavourite - Create migration to create a
board_userrecord for each board a user belongs (all in every workspace they belong to) and check against theboard_user_favouritestable to setisFavourite - Adding a new board should create a
board_userrecord - Updating the
positionshould reorder theboard_userrecords - Deleting a board should remove any
board_userrecords for that board - Favouriting/unfavouriting a board should update the
board_userrecord - Boards should be ordered by their position/isFavourite for a given user
Sorry for the dump - there's quite a lot to do here so I'm very happy to help. Just give me a shout if you've got any questions
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.
This pull request contains feature for reordering boards by drag-and-drop through the UI:
on error