feat: add pinned tag functionality and UI enhancements
- Introduced `isPinned` property to the `Tag` model for marking main objectives. - Updated `TagForm` to include a checkbox for setting tags as pinned, enhancing user interaction. - Enhanced `KanbanBoardContainer` to display pinned tasks in a dedicated `ObjectivesBoard`, improving task visibility. - Modified `KanbanFilters` to support filtering by pinned tags, streamlining task management. - Adjusted `TasksContext` to separate pinned tasks from regular tasks for better organization.
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
-- RedefineTables
|
||||
PRAGMA defer_foreign_keys=ON;
|
||||
PRAGMA foreign_keys=OFF;
|
||||
CREATE TABLE "new_tags" (
|
||||
"id" TEXT NOT NULL PRIMARY KEY,
|
||||
"name" TEXT NOT NULL,
|
||||
"color" TEXT NOT NULL DEFAULT '#6b7280',
|
||||
"isPinned" BOOLEAN NOT NULL DEFAULT false
|
||||
);
|
||||
INSERT INTO "new_tags" ("color", "id", "name") SELECT "color", "id", "name" FROM "tags";
|
||||
DROP TABLE "tags";
|
||||
ALTER TABLE "new_tags" RENAME TO "tags";
|
||||
CREATE UNIQUE INDEX "tags_name_key" ON "tags"("name");
|
||||
PRAGMA foreign_keys=ON;
|
||||
PRAGMA defer_foreign_keys=OFF;
|
||||
@@ -36,10 +36,11 @@ model Task {
|
||||
}
|
||||
|
||||
model Tag {
|
||||
id String @id @default(cuid())
|
||||
name String @unique
|
||||
color String @default("#6b7280")
|
||||
taskTags TaskTag[]
|
||||
id String @id @default(cuid())
|
||||
name String @unique
|
||||
color String @default("#6b7280")
|
||||
isPinned Boolean @default(false) // Tag pour objectifs principaux
|
||||
taskTags TaskTag[]
|
||||
|
||||
@@map("tags")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user