From 4bf24dd602d892a676f2eda89d6703d7560a6931 Mon Sep 17 00:00:00 2001 From: Methapon Metanipat Date: Thu, 7 Nov 2024 13:49:26 +0700 Subject: [PATCH] feat: add field for storing institution --- prisma/schema.prisma | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 5432747..ff251d9 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -977,15 +977,25 @@ model WorkflowTemplate { service Service[] } +model WorkflowTemplateStepInstitution { + id String @id @default(cuid()) + + group String + + workflowTemplateStep WorkflowTemplateStep @relation(fields: [workflowTemplateStepId], references: [id]) + workflowTemplateStepId String +} + model WorkflowTemplateStep { id String @id @default(cuid()) - order Int - name String - detail String? - type String? - value WorkflowTemplateStepValue[] // NOTE: For enum or options type - responsiblePerson WorkflowTemplateStepUser[] + order Int + name String + detail String? + type String? + value WorkflowTemplateStepValue[] // NOTE: For enum or options type + responsiblePerson WorkflowTemplateStepUser[] + responsibleInstitution WorkflowTemplateStepInstitution[] workflowTemplate WorkflowTemplate? @relation(fields: [workflowTemplateId], references: [id]) workflowTemplateId String?