feat: add schedule start and end validation in OrderSchema
- Introduced new validation fields for schedule start and end times in the OrderSchema to ensure accurate scheduling. - This enhancement aims to improve the integrity of scheduling operations by validating the start and end times against the provided schedule data.
This commit is contained in:
@@ -432,6 +432,12 @@ export class OrderSchema extends PothosSchema {
|
||||
(scheduleDate) => scheduleDate.scheduleId
|
||||
),
|
||||
},
|
||||
start: {
|
||||
equals: args.data.schedule.connect?.scheduleStart as Date,
|
||||
},
|
||||
end: {
|
||||
equals: args.data.schedule.connect?.scheduleEnd as Date,
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user