11 lines
427 B
GraphQL
11 lines
427 B
GraphQL
type Message @table(name: "messages") {
|
|
id: UUID! @default(expr: "uuidV4()")
|
|
conversationId: UUID! # conversation_id (FK lógica a Conversation.id)
|
|
senderName: String!
|
|
content: String!
|
|
readBy: String # read_by (jsonb -> String, array de user IDs)
|
|
createdDate: Timestamp @default(expr: "request.time")
|
|
updatedDate: Timestamp @default(expr: "request.time")
|
|
createdBy: String @default(expr: "auth.uid")
|
|
}
|