run eslint

This commit is contained in:
2024-10-15 20:05:54 +07:00
parent c208c27a64
commit 7d7765c70f
15 changed files with 833 additions and 780 deletions

View File

@@ -47,7 +47,7 @@ export class CategorySchema extends PothosSchema {
categories: t.prismaField({
type: [this.category()],
args: this.builder.generator.findManyArgs('Category'),
resolve: async (query, root, args, ctx, info) => {
resolve: async (query, root, args) => {
return await this.prisma.category.findMany({
...query,
skip: args.skip ?? undefined,
@@ -60,7 +60,7 @@ export class CategorySchema extends PothosSchema {
category: t.prismaField({
type: this.category(),
args: this.builder.generator.findUniqueArgs('Category'),
resolve: async (query, root, args, ctx, info) => {
resolve: async (query, root, args) => {
return await this.prisma.category.findUnique({
...query,
where: args.where ?? undefined,
@@ -70,7 +70,7 @@ export class CategorySchema extends PothosSchema {
subCategories: t.prismaField({
type: [this.subCategory()],
args: this.builder.generator.findManyArgs('SubCategory'),
resolve: async (query, root, args, ctx, info) => {
resolve: async (query, root, args) => {
return await this.prisma.subCategory.findMany({
...query,
where: args.filter ?? undefined,
@@ -92,7 +92,7 @@ export class CategorySchema extends PothosSchema {
required: true,
}),
},
resolve: async (query, root, args, ctx, info) => {
resolve: async (query, root, args) => {
return await this.prisma.category.create({
data: args.input,
});
@@ -106,7 +106,7 @@ export class CategorySchema extends PothosSchema {
required: true,
}),
},
resolve: async (query, root, args, ctx, info) => {
resolve: async (query, root, args) => {
return await this.prisma.category.createManyAndReturn({
data: args.data,
skipDuplicates: true,
@@ -122,7 +122,7 @@ export class CategorySchema extends PothosSchema {
required: true,
}),
},
resolve: async (query, root, args, ctx, info) => {
resolve: async (query, root, args) => {
return await this.prisma.subCategory.create({
data: args.input,
});