feat: Introduce default profile sections and fields, updating schema with isSystem and isSearchableOnly properties.
This commit is contained in:
@@ -224,6 +224,7 @@ model ProfileSection {
|
||||
sortOrder Int @default(0)
|
||||
isActive Boolean @default(true)
|
||||
isGlobal Boolean @default(false) // If true, applies to ALL agent types
|
||||
isSystem Boolean @default(false) // If true, section cannot be deleted (system default)
|
||||
|
||||
// Timestamps
|
||||
createdAt DateTime @default(now())
|
||||
@@ -234,6 +235,7 @@ model ProfileSection {
|
||||
agentTypeSections AgentTypeSection[]
|
||||
|
||||
@@index([isActive])
|
||||
@@index([isSystem])
|
||||
@@index([sortOrder])
|
||||
@@map("profile_sections")
|
||||
}
|
||||
@@ -273,6 +275,7 @@ model ProfileField {
|
||||
sortOrder Int @default(0)
|
||||
isActive Boolean @default(true)
|
||||
isRequired Boolean @default(false)
|
||||
isSearchableOnly Boolean @default(false) // If true, shown in edit form & search, but hidden on public profile
|
||||
|
||||
// Validation rules (JSON)
|
||||
validation Json? // { min, max, minLength, maxLength, pattern, etc. }
|
||||
|
||||
Reference in New Issue
Block a user