feat(ST-1109.2): add PbiStatus enum and status field to Pbi model
- New PbiStatus enum (READY/BLOCKED/DONE) for PBI lifecycle tracking - Pbi.status PbiStatus @default(READY) - Index on (product_id, status) for filter queries - Migration: 20260429150643_add_pbi_status - ERD regenerated via prisma generate Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
50faebb82c
commit
b049822f8f
3 changed files with 19 additions and 3 deletions
File diff suppressed because one or more lines are too long
|
Before Width: | Height: | Size: 400 KiB After Width: | Height: | Size: 414 KiB |
|
|
@ -0,0 +1,8 @@
|
|||
-- CreateEnum
|
||||
CREATE TYPE "PbiStatus" AS ENUM ('READY', 'BLOCKED', 'DONE');
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "pbis" ADD COLUMN "status" "PbiStatus" NOT NULL DEFAULT 'READY';
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "pbis_product_id_status_idx" ON "pbis"("product_id", "status");
|
||||
|
|
@ -23,6 +23,12 @@ enum StoryStatus {
|
|||
DONE
|
||||
}
|
||||
|
||||
enum PbiStatus {
|
||||
READY
|
||||
BLOCKED
|
||||
DONE
|
||||
}
|
||||
|
||||
enum TaskStatus {
|
||||
TO_DO
|
||||
IN_PROGRESS
|
||||
|
|
@ -131,12 +137,14 @@ model Pbi {
|
|||
description String?
|
||||
priority Int
|
||||
sort_order Float
|
||||
created_at DateTime @default(now())
|
||||
updated_at DateTime @updatedAt
|
||||
status PbiStatus @default(READY)
|
||||
created_at DateTime @default(now())
|
||||
updated_at DateTime @updatedAt
|
||||
stories Story[]
|
||||
|
||||
@@unique([product_id, code])
|
||||
@@index([product_id, priority, sort_order])
|
||||
@@index([product_id, status])
|
||||
@@map("pbis")
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue