update order and service
This commit is contained in:
Submodule epess-database updated: f04e7842a2...297ffedf94
@@ -42,6 +42,9 @@ export class OrderSchema extends PothosSchema {
|
||||
total: t.exposeInt('total', {
|
||||
description: 'The total price of the order.',
|
||||
}),
|
||||
scheduleId: t.exposeID('scheduleId', {
|
||||
description: 'The ID of the schedule.',
|
||||
}),
|
||||
createdAt: t.expose('createdAt', {
|
||||
type: 'DateTime',
|
||||
description: 'The date and time the order was created.',
|
||||
@@ -62,6 +65,9 @@ export class OrderSchema extends PothosSchema {
|
||||
refundTicket: t.relation('refundTicket', {
|
||||
description: 'The refund ticket for the order.',
|
||||
}),
|
||||
schedule: t.relation('schedule', {
|
||||
description: 'The schedule for the order.',
|
||||
}),
|
||||
}),
|
||||
});
|
||||
}
|
||||
@@ -104,7 +110,10 @@ export class OrderSchema extends PothosSchema {
|
||||
description: 'Create a new order.',
|
||||
args: {
|
||||
data: t.arg({
|
||||
type: this.builder.generator.getCreateInput('Order'),
|
||||
type: this.builder.generator.getCreateInput('Order', [
|
||||
'status',
|
||||
'total',
|
||||
]),
|
||||
required: true,
|
||||
}),
|
||||
},
|
||||
@@ -136,7 +145,10 @@ export class OrderSchema extends PothosSchema {
|
||||
description: 'Update an existing order.',
|
||||
args: {
|
||||
data: t.arg({
|
||||
type: this.builder.generator.getUpdateInput('Order'),
|
||||
type: this.builder.generator.getUpdateInput('Order', [
|
||||
'status',
|
||||
'total',
|
||||
]),
|
||||
required: true,
|
||||
}),
|
||||
where: t.arg({
|
||||
|
||||
@@ -35,6 +35,9 @@ export class ServiceSchema extends PothosSchema {
|
||||
description: t.exposeString('description', {
|
||||
description: 'The description of the service.',
|
||||
}),
|
||||
content: t.exposeString('content', {
|
||||
description: 'The content of the service.',
|
||||
}),
|
||||
centerId: t.exposeID('centerId', {
|
||||
description: 'The ID of the center that offers the service.',
|
||||
}),
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user