modification schema of event

This commit is contained in:
José Salazar
2025-12-18 19:10:35 -05:00
parent b1dd5629c4
commit 6101a56a60
3 changed files with 99 additions and 7 deletions

View File

@@ -22,7 +22,7 @@ mutation CreateEvent(
$contractType: ContractType,
$poReference: String,
$status: EventStatus!,
$date: Timestamp!,
$date: String!,
$shifts: Any,
$addons: Any,
$total: Float,
@@ -32,7 +32,19 @@ mutation CreateEvent(
$invoiceId: UUID,
$notes: String,
$requested: Int,
$assignedStaff: Any
$assignedStaff: Any,
$department: String,
$createdBy: String,
$orderType: String,
$recurringStartDate: String,
$recurringEndDate: String,
$recurringDays: Any,
$permanentStartDate: String,
$permanentDays: Any,
$includeBackup: Boolean,
$backupStaffCount: Int,
$recurringTime: String,
$permanentTime: String
) @auth(level: USER) {
event_insert(
data: {
@@ -68,8 +80,20 @@ mutation CreateEvent(
clientPhone: $clientPhone
invoiceId: $invoiceId
notes: $notes
orderType: $orderType
requested: $requested
assignedStaff: $assignedStaff
department: $department
createdBy: $createdBy
recurringStartDate: $recurringStartDate
recurringEndDate: $recurringEndDate
recurringDays: $recurringDays
permanentStartDate: $permanentStartDate
permanentDays: $permanentDays
includeBackup: $includeBackup
backupStaffCount: $backupStaffCount
recurringTime: $recurringTime
permanentTime: $permanentTime
}
)
}
@@ -100,7 +124,7 @@ mutation UpdateEvent(
$contractType: ContractType,
$poReference: String,
$status: EventStatus,
$date: Timestamp,
$date: String,
$shifts: Any,
$addons: Any,
$total: Float,
@@ -110,7 +134,19 @@ mutation UpdateEvent(
$invoiceId: UUID,
$notes: String,
$requested: Int,
$assignedStaff: Any
$orderType: String,
$department: String,
$assignedStaff: Any,
$createdBy: String,
$recurringStartDate: String,
$recurringEndDate: String,
$recurringDays: Any,
$permanentStartDate: String,
$permanentDays: Any,
$includeBackup: Boolean,
$backupStaffCount: Int,
$recurringTime: String,
$permanentTime: String
) @auth(level: USER) {
event_update(
id: $id,
@@ -147,8 +183,20 @@ mutation UpdateEvent(
clientPhone: $clientPhone
invoiceId: $invoiceId
notes: $notes
orderType: $orderType
requested: $requested
assignedStaff: $assignedStaff
department: $department
createdBy: $createdBy
recurringStartDate: $recurringStartDate
recurringEndDate: $recurringEndDate
recurringDays: $recurringDays
permanentStartDate: $permanentStartDate
permanentDays: $permanentDays
includeBackup: $includeBackup
backupStaffCount: $backupStaffCount
recurringTime: $recurringTime
permanentTime: $permanentTime
}
)
}

View File

@@ -45,7 +45,18 @@ query listEvents (
notes
requested
assignedStaff
orderType
department
createdBy
recurringStartDate
recurringEndDate
recurringDays
permanentStartDate
permanentDays
includeBackup
backupStaffCount
recurringTime
permanentTime
}
}
@@ -87,7 +98,18 @@ query getEventById(
invoiceId
notes
requested
orderType
department
assignedStaff
recurringStartDate
recurringEndDate
recurringDays
permanentStartDate
permanentDays
includeBackup
backupStaffCount
recurringTime
permanentTime
}
}
@@ -99,7 +121,7 @@ query filterEvents(
$isRapid: Boolean,
$isMultiDay: Boolean,
$recurrenceType: RecurrenceType,
$date: Timestamp,
$date: String,
$hub: String,
$eventLocation: String,
$contractType: ContractType,
@@ -155,6 +177,17 @@ query filterEvents(
notes
requested
assignedStaff
orderType
department
createdBy
recurringStartDate
recurringEndDate
recurringDays
permanentStartDate
permanentDays
includeBackup
backupStaffCount
recurringTime
permanentTime
}
}

View File

@@ -46,14 +46,14 @@ type Event @table(name: "events") {
detectedConflicts: Any
businessId: UUID!
businessName: String
vendorId: String
vendorId: String @default(expr: "auth.uid")
vendorName: String
hub: String
eventLocation: String
contractType: ContractType
poReference: String
status: EventStatus!
date: Timestamp!
date: String!
shifts: Any
addons: Any
total: Float
@@ -64,6 +64,17 @@ type Event @table(name: "events") {
notes: String
requested: Int @default(expr: "0")
assignedStaff: Any
orderType: String
department: String
recurringStartDate: String
recurringEndDate: String
recurringDays: Any
permanentStartDate: String
permanentDays: Any
includeBackup: Boolean
backupStaffCount: Int
recurringTime: String
permanentTime: String
createdDate: Timestamp @default(expr: "request.time")
updatedDate: Timestamp @default(expr: "request.time")
createdBy: String @default(expr: "auth.uid")